Worked solution from the System Software Paper 1 Theory Fundamentals booklet, Part 2 of 2.
Describe a compiler. Any two of these score:
It tries to translate the whole source code at once [1]
It makes a separate error report at the end of translation [1]
If there are no errors it creates an executable file (also scores if the marks above are not already full)
Describe an interpreter. Both points score:
It reads each line, translates it and runs it [1]
It stops when it finds an error and shows the error there [1]
Writing (max 2). Any two of these:
Pretty printing or colour to show key words [1]
Context-sensitive prompts, auto-complete or auto-formatting to help type code [1]
Other accepted answers: expand and collapse code blocks; dynamic syntax checking.
Testing (max 2). Any two of these:
Single stepping to run the code one line at a time [1]
Breakpoints to stop at set points and check values [1]
A report window shows how variables change.
▶ Whole paper
Video solution of the whole paper · by Exam Ninja. 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.