AQA GCSE Computer Science Paper 1, June 2025: question 9

A PrepWise guide to a real paper, with our descriptions and answers. Not made or approved by AQA.

PrepWise guide: AQA GCSE Computer Science Paper 1Question 99 of 11

Figure 9 shows five pseudo-code algorithms, A to E. Each is meant to add up the five values stored in the array numbers. Some of them do not work.

Figure 9
Five pseudo-code algorithms in framed boxes, each with a letter A to E in a grey strip on its left edge.Open full size to read the labels (Figure 9, opens in a new tab)
09[2 marks]

Tick one row in each column A to E: does that algorithm total all five values, or not?

See how you would score on Trace Tables

Our own questions on this topic, marked straight away, so you see what to revise. Free now.

Show model answerHide model answer
                                A   B   C   D   E
Totals the five values          ✓   ✓
Does not total them                     ✓   ✓   ✓

C loops to position 7, which is past the end of the array, and it skips position 0. D never starts, because total is 0 and the loop needs it above 0. E never changes x, so it never stops.

2 marks

How the marks are earned

  1. Any three columns correct earns one mark.
  2. All five columns correct earns both marks.
  3. A column with more than one tick earns nothing for that column.
  4. A and B total the five values. C, D and E do not.

Why it scores

A and B visit all five positions, 0 to 4, and add each value. C, D and E each fail, as the next paragraph shows.

These are the reasons for the three ticks in the second row. Each algorithm fails to produce the correct total.

Revise Trace Tables
AQA owns the copyright in its exam questions, so we cannot copy their wording. These descriptions and answers are ours. Not made or approved by AQA.[2 marks]