- A binary search will search an
**ordered** list to find out whether a particular item is in the list. If it is in the list, it will locate its position in the list.
- A binary search concentrates on the midpoint of an ever-halving list, so it is very quick.

Algorithm:

To search an ordered list of *n* items for a target T:

1. Select the middle item in the list, *m* (use n+1/2 and round up if necessary)

2. i) if T=m, the target is located and the search is complete

ii) if T is before m, it cannot be in the second half of the list, so that half, and m, are discarded

iii) if T is after m, it cannot be in the first half of the list, so that half, and m, are discarded

## Comments

No comments have yet been made