Select one option to show which of the following is the false statement about the algorithm in Figure 1.
Figure 1
1 nums ← [12, 5, 8, 5, 14]
2 hasDuplicate ← false
3 p ← 0
4 WHILE p < 5 AND hasDuplicate = false
5 q ← p + 1
6 WHILE q < 5 AND hasDuplicate = false
7 IF nums[p] = nums[q] THEN
8 hasDuplicate ← true
9 ENDIF
10 q ← q + 1
11 ENDWHILE
12 p ← p + 1
13 ENDWHILE
The algorithm uses definite iteration
The algorithm uses nested iteration
The algorithm uses a boolean variable
The algorithm uses selection
208 exam-style questions on AQA GCSE Computer Science Representing algorithms. Each one has a worked solution and a mark scheme showing where the marks go.