Worked solution from the Programming Paper 2 Algorithms, Programming and Logic booklet, Part 1 of 3.
Write three points (one mark each):
Give variables and constants meaningful identifiers, so programmers (and future programmers) can understand their purpose [1]
Constants store values that never change while the program runs, for example a fixed tax rate [1]
Variables store values that can change while the program runs, for example a total that is calculated [1]
Also accepted: both are used for data storage.
▶ Whole paper
Video solution of the whole paper · by Paper solver.. 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.