27Easy
0/1

An algorithm is shown in the pseudocode in Figure 1.

Figure 1

1  total_cost ← 0.00
2  count ← USERINPUT
3  WHILE count > 0 DO
4      item_price ← USERINPUT
5      total_cost ← total_cost + item_price
6      count ← count - 1
7  ENDWHILE

Select the option that identifies the line number where a relational operator is first used in the algorithm in Figure 1.

Line 1

Line 2

Line 3

Line 5

Programming concepts Questions

Practise AQA GCSE Computer Science Programming concepts with exam-style questions for GCSE Computer Science. 100 questions, matched to the AQA GCSE Computer Science (8525) specification and written in Paper 1 and Paper 2 style. Every question includes a full worked solution and mark scheme, so you can see where marks are awarded rather than just whether you got the answer right.

PreviousNext

Programming concepts Questions

  1. GCSE
  2. /Computer Science
  3. /Programming concepts