Worked solution from the Software Development Paper 2 Problem-solving and Programming booklet, Part 3 of 3.
Write one point: the best life cycle depends on the project, for example its size, the team's skills, or whether requirements can change [1]
Write one point: which language suits the problem (here controlling a production line) [1]
Any three reasons:
Requirements change for the production line [1]
New hardware or technology becomes available [1]
Library modules used change, or the law changes [1]
Write: perfective (or corrective) maintenance [1]
Work out the type of each result:
| Expression | Data type |
|---|---|
| RIGHT(MachineCode, 4) | STRING |
| Speed * 2.5 | REAL |
| NOT Status | BOOLEAN |
| IS_NUM(Check) | BOOLEAN |
STRING [1]
REAL [1]
BOOLEAN [1]
BOOLEAN [1]
Product[x, y] has two indexes.
Write: 2 [1]
x has 100 values (0 to 99) and y has 10 values (0 to 9). 100 × 10 = 1000 [1]
Use the bounds and the type for a whole number:
DECLARE Product : ARRAY[0:99, 0:9] OF INTEGER
Correct bounds [0:99, 0:9] [1]
The rest of the declaration (DECLARE, name, ARRAY ... OF INTEGER) [1]
▶ Whole paper
Video solution of the whole paper · by Awab Aqib. 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.