2210/22/O/N/20 question 2: worked solution (October/November 2020, paper 22)
Show as plain textHide plain text
Cambridge O Level Computer Science 2210 · 8.1 Programming concepts Worked solution from the Programming Paper 2 Algorithms, Programming and Logic booklet, Part 1 of 3. Q5 2210/22/O/N/20 original Q2 Structured · 2 marks Worked solution (a) A subroutine is a self-contained block of code that is called from a program. It is not a whole program. Only a function has to return a value. Statement true false A subroutine is called from within a program. ✓ A subroutine is not a complete program. ✓ A subroutine is a self-contained piece of code. ✓ A subroutine must return a value to the code from which it was called. ✓ All four rows correct [2] Two correct rows score 1 mark. KEY IDEA A subroutine is self-contained and called by a program; only a function must return a value. TOTAL 2 marks Official mark scheme VIDEO ▶ Whole paper Video solution of the whole paper · by Quixotic Academy. Tap the picture to open it on YouTube.