Cambridge O Level Computer Science 2210 · 7.6 Suitable test data

Q40 · 2210/22/O/N/24 Q8

Worked solution from the Algorithm design and problem-solving Paper 2 Algorithms, Programming and Logic booklet, Part 5 of 8.

Q402210/22/O/N/24original Q8Structured · 4 marks
Question 8 from 2210/22/O/N/24

Worked solution

Test the limit of 80 with two values: the last one accepted and the first one rejected.

Test data 1: 80 [1]

Reason: it is the largest whole number that is accepted, at the very limit (extreme/boundary data) [1]

Test data 2: 81 [1]

Reason: it is the smallest whole number that is rejected, just over the limit (boundary/abnormal data) [1]

KEY IDEABoundary testing uses the last value that is accepted and the first value that is rejected.
TOTAL 4 marks

Official mark scheme

Mark scheme for 2210/22/O/N/24 question 8
VIDEO
▶ Topic lesson

A lesson on this topic · by Craig'n'Dave. Tap the picture to open it on YouTube.

Solutions follow the official Cambridge mark schemes; marks are shown in grey. Videos are from other YouTube channels. Paper codes read component / series / year: M/J = May/June, O/N = October/November. Past-paper questions © UCLES, reproduced for classroom practice.