Worked solution from the Programming Paper 2 Algorithms, Programming and Logic booklet, Part 1 of 3.
Procedures (give two points):
A procedure lets you write a group of statements under one name [1]
It lets you build a modular program, and the procedure can be re-used in the program or in other programs [1]
Parameters (give two points):
Parameters pass values from the main program into a procedure or function [1]
...so the values can be used inside the procedure, which can then be re-used with different data [1]
Other accepted points: re-use makes programs faster to write and shorter; different programmers can work on different procedures; shorter programs are easier to maintain. Four marks in total.
▶ 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.