In binary search, if the middle element is greater than the key, search the:
AFixed half
BFuller half
CFirst half
DFinal half
Answer & Solution
Correct answer: C. First half
1. The list is in order, so everything after the middle is larger still.
2. The key can only lie before the middle.
3. If the middle element is greater than the key, the key must be in the first half.
4. So the answer is the first half.
_Source: syllabus Computer Science, Ch 5 'Sorting' and Ch 6 'Searching'_
Keep practising Sorting and Searching
Browse all Sorting and Searching questions for IGNOU MCA, or explore more Computer Science topics.