Worked solution from the Software Paper 1 Computer Systems booklet, Part 2 of 2.
Write one other similarity:
Both check for errors (or report errors) [1]
Give two differences and explain each. Say what the interpreter does and what the compiler does.
Difference 1: an interpreter translates the code line by line and runs each line straight away [1]
... whereas a compiler translates the whole code at the same time, before it is run [1]
Difference 2: an interpreter stops and reports an error as it meets it, and runs the code up to that point [1]
... whereas a compiler makes an error report at the end and will not run the code if there is an error [1]
Other accepted differences: a compiler produces an executable file but an interpreter does not; an interpreter is needed every time the program runs, but a compiler is not.
▶ Starts at Q6 (8:50)
Starts at Q6 (8:50) · by Ace Academy. 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.