Which is the most efficient way to find an item in a sorted list of 1,000 items?
- Repeatedly halve the list and check the middle item
- Print all numbers from 1 to 1000
- Shuffle the list and check randomly
- Check every item one by one from the start
Answer
A) Repeatedly halve the list and check the middle item
Halving the search space (binary search) needs at most about 10 comparisons for 1,000 items. SLO CS-11-B-01 · Application
Computer Science MCQ · More Unit 2: Computational Thinking and Algorithms MCQs · Practise