Computing Atlas

How Computing Was Built
Concepts

Binary Search

Also Known As Half-Interval Search
Algorithm

Citation Formats

General Reference

APA Style

BibTeX

Binary search is a search algorithm that finds the position of a target value within a sorted array by repeatedly halving the portion that could contain it. It runs in logarithmic time in the worst case, making O(log n) comparisons for n elements, which is why keeping data sorted pays: a million entries need about twenty questions, not a million. Deceptively simple, it is a famous source of subtle implementation errors, and a variant omitting one check was first published correctly by Hermann Bottenbruch in 1962.

Facts
Origin Year
1946 1
John Mauchly described the basic idea in 1946, but the first correctly published bug-free binary search algorithm did not appear until 1962 (Hermann Bottenbruch); Donald Knuth cites this gap as a famous case of a simple idea being surprisingly tricky to implement correctly.
Core Principle
Halve the search space with every comparison: ask of the middle element whether the target lies before or after it, and discard the half that cannot contain it. 1
Cross-Tradition Connections

Associated With

John Mauchly, Pioneers

John Mauchly described the basic idea of binary search in a 1946 lecture, already the cited source for this concept's own origin-year fact.

In Field

Sources
1. Wikipedia: Binary Search
Wikimedia FoundationOpening and Performance sections
Quote, Opening and Performance sections
Binary search is a search algorithm that finds the position of a target value within a sorted array.
View the Source
1. Wikipedia: Binary Search
Wikimedia FoundationPerformance section
Quote, Performance section
Binary search runs in logarithmic time in the worst case, making O(log n) comparisons, where n is the number of elements in the array.
View the Source
1. Wikipedia: Binary Search
Wikimedia FoundationIntroductionView the Source
1. Wikipedia: Binary Search
Wikimedia FoundationHistory sectionView the Source
1. Wikipedia: Binary Search
Wikimedia FoundationAssociated With: John MauchlyView the Source
Comments (0)
No comments yet. Be the first to share a thought.
Reader Challenges (0 open reader challenges)
No disputes yet. Spotted an error or a better source? Open the first one.

View At A Past Year

The atlas records no dated fact of its own for this entry, so there is no other year to choose.