Submodule 4 of 5
Binary Search & Boundary Conditions
Loop invariants, half-open vs closed intervals, lower_bound and upper_bound, and off-by-one proofs.
Question Difficulty Success
Learning resources
- CMU 15-122, Binary Search with loop invariants cs.cmu.edu (opens in a new tab)
- Google Research, nearly all binary searches are broken research.google (opens in a new tab)
- USACO Guide, Binary Search usaco.guide (opens in a new tab)
- Python docs, bisect module semantics docs.python.org (opens in a new tab)
Up next
1 of 1 question here is still unsolved.