Neco 2020 Computer Studies Question 41
Practice objective / multiple choice question 41 from the 2020 Neco Computer Studies examination.
Consider the following Python program: ``` def mystery(x): total = 0 for i in range(1, x+1): if i % 2 == 0: total += i//2 else: total += 3*i + 1 return total print(mystery(5)) ``` What is the output printed by this program?
Answer Options
About This Question
This is Neco 2020 Computer Studies Question 41. It is one of the objective questions from the 2020 Neco Computer Studies examination.
Difficulty level: Medium .
Master the Exam!
You've seen a preview, but there are thousands more questions plus AI tutor to break down complex solutions.