City Guilds Model Questions Vol1 2021 Information Technology Question 21

Practice objective / multiple choice question 21 from the 2021 City Guilds Model Questions Vol1 Information Technology examination.

City Guilds Model Questions Vol1 2021 Information Technology Objective / Multiple Choice Hard Difficulty
Question 21 CITY_GUILDS_MODEL_QUESTIONS_VOL1 • 2021 • INFORMATION_TECHNOLOGY • objective

Consider the following pseudo‑code: ``` integer n = 1, total = 0, count = 0 while count < 5 do integer s = 0 for i = 1 to n do if i mod 3 = 0 then s = s + i else if i mod 2 = 0 then s = s + 2*i end if end for if s mod 4 = 0 then count = count + 1 end if n = n + 1 end while output n ``` What integer is printed when the program terminates?

Answer Options

A. 23
B. 30
C. 25
Correct Answer D. 24
Correct Answer
D
Correct Option:
24

About This Question

This is City Guilds Model Questions Vol1 2021 Information Technology Question 21. It is one of the objective questions from the 2021 City Guilds Model Questions Vol1 Information Technology examination.

Difficulty level: Hard .

Master the Exam!

You've seen a preview, but there are thousands more questions plus AI tutor to break down complex solutions.

Unlock Full Access Available for Android & Windows
Chat with Support