Skip to main content
O-LevelComputer ScienceAlgorithm design and problem-solving2210/23 · Oct/Nov 2023 · Q49 Marks

A programmer is writing a data entry program for booking theatre seats. The programmer needs the program to accept only whole numbers that are greater than or equal to one and less than or equal to six.

  1. (a)Give the names of two validation checks that are required for this program. 1 2[2]
  2. (b)Complete this pseudocode to perform your two validation checks, using your answers given in (a): OUTPUT "Please enter the number of seats you want to book " INPUT Seats[5]
  3. (c)Give one item of test data to use when testing this program. State the reason for your choice of test data. Test data Reason for choice[2]

Mark scheme

Marking points from the official mark scheme (Oct/Nov 2023). The mark or mark type is shown in brackets.

  1. [2] One mark for each point type check range check
  2. [5] One mark for each point (max five) use of loop for check checking for whole number checking for number greater than or equal to one ... and less than or equal to six Appropriate error/reinput message ability to reinput value Example: WHILE Seats < 1 OR Seats > 6 OR Seats <> ROUND(Seats, 0) DO OUTPUT "Please enter a valid number of seats " INPUT Seats ENDWHILE
  3. [2] One mark for correct test data, one mark for corresponding reason Example: 7, abnormal data to show that this value would be rejected

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
Algorithm design and problem-solving, O-Level Computer Science (syllabus 2210). Structured question, 9 marks.
Source
O-Level Computer Science, Oct/Nov 2023 Paper 2 Variant 3, question 4.

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