Skip to main content
O-LevelComputer ScienceProgramming2210/21 · May/June 2025 · Q34 Marks

The following pseudocode algorithm uses a count-controlled loop to read in 10 names and store them in the array Names [] FOR Count ← 1 TO 10 OUTPUT "Please enter a name" INPUT Name Names [Count] ← Name NEXT Count Rewrite the algorithm in pseudocode, using a condition-controlled loop instead of a count-controlled loop.

  1. The following pseudocode algorithm uses a count-controlled loop to read in 10 names and store them in the array Names [] FOR Count ← 1 TO 10 OUTPUT "Please enter a name" INPUT Name Names [Count] ← Name NEXT Count Rewrite the algorithm in pseudocode, using a condition-controlled loop instead of a count-controlled loop.[4]

Mark scheme

Marking points from the official mark scheme (May/June 2025). The mark or mark type is shown in brackets.

  1. [1] Initialising a count variable outside of loop
  2. [1] Correct use of loop with condition for 10 times (WHILE (DO)...ENDWHILE, REPEAT...UNTIL) with close
  3. [1] Incrementing the count variable inside the loop
  4. [1] Rest of algorithm correct
  5. Example: Count ← 1 REPEAT OUTPUT "Please enter a name" INPUT Name Names [Count] ← Name Count ← Count + 1 UNTIL Count > 10 Or Count ← 1 WHILE Count <= 10 DO OUTPUT "Please enter a name" INPUT Name Names [Count] ← Name Count ← Count + 1 ENDWHILE

Write your answer and get it marked

On Oracle Prep you can write or photograph your own answer and have it marked by AI against this mark scheme, with feedback on what you missed.

Sign up free →

About this question

Topic
Programming, O-Level Computer Science (syllabus 2210). Structured question, 4 marks.
Source
O-Level Computer Science, May/June 2025 Paper 2 Variant 1, question 3.

Questions and mark schemes are from past examination papers and remain the copyright of the exam board. How Oracle Prep builds its content

Related Computer Science questions

© 2026 Oracle Prep