Question 8

AQA Computer Science June 2019 Paper 1GCSE4 marks

On the specification

8.1
3.1 Fundamentals of algorithms
8.2
3.1 Fundamentals of algorithms
Question text

8.1 State the comparisons that would be made if the binary search algorithm was box used to search for the value 30 in the following array (array indices have been included above the array). 1 2 3 4 5 6 16 14 21 27 31 35 [3 marks] 8.2 For a binary search algorithm to work correctly on an array of integers, what property must be true about the array? [1 mark]