May/June 2026 Paper 22

2026 · 10 questions · 20 parts · 75 marks

0/75 marks
0Correct0Partial0Wrong20Unattempted
Filters0 active

Questions

Select a part to jump to its question

Finish set
Q1–/1 mk
Q2–/1 mk
Q4–/6 mks
Q5–/10 mks
Q6–/7 mks
Q7–/5 mks
Q8–/9 mks
Q9–/10 mks
Q10–/15 mks
Context for question 5
The purpose of this pseudocode algorithm is to find the name of a customer using an account ID, which contains letters and numbers. The name of the customer and the account ID are stored in the prepopulated two-dimensional (2D) array Accounts[]. The algorithm would then output the name of the customer.
For example, Accounts[1, 1] contains the account ID of the first customer and Accounts[1, 2] contains the name of the first customer.
pseudocode
DECLARE Accounts : ARRAY[1:1000, 1:2] OF STRINGDECLARE Row : INTEGERDECLARE AccountID : INTEGEROUTPUT "Please enter an account ID "OUTPUT AccountIDFOR Row ← 1 TO 1000    CASE OF AccountID = Accounts[Row, 1]      THEN        OUTPUT "The customer’s name is ", Accounts[1, 2]    ENDIFNEXT Row
5(a)Searching AlgorithmsMedium4 marks
Identify the line numbers of four errors in the pseudocode and suggest corrections.

Answer

0 words
5(b)Searching AlgorithmsEasy1 mark
State the name given to this type of algorithm.
5(c)Searching AlgorithmsHard5 marks
The algorithm stops if the account number is not found in the array.
Write the pseudocode statements to change the algorithm to inform the user that the account number has not been found in the array.
Clearly state where in the original algorithm your new statements would be placed.
Do not rewrite the whole algorithm.

Answer

0 words