Codele / Algorithms

Binary search

Guess a number from 1 to 100 and a friend says “higher” or “lower”. You never guess from the start: you guess the middle and throw half away. That is binary search.

Loading the playable lesson…