Foundations - Logarithms for Engineers
A logarithm asks 'how many times must I halve (or double)?' - the math hiding inside binary search, balanced trees, and every O(log n) promise.
The only definition you need
log₂(16) asks: '2 raised to what power gives 16?' Answer: 4. Equivalently: 'how many times can I halve 16 before reaching 1?' Same answer - and that halving view is what engineers use.
log₂(32) equals…
Where you will see it
Real systems that use this exact idea. Tap a card to open it.
Common traps
The mistakes interviewers watch for. Guess the fix, then reveal it.
FixEngineers default to log₂; other bases differ only by a dropped constant.
FixLinear grows with input; logarithmic grows with the number of halvings.
FixCount the cuts instead - it generalizes to any number instantly.
Interview prep
Questions you could be asked, with the depth an interviewer wants to hear.
Each comparison discards half the remaining items; reaching one item takes log₂(n) halvings.
halving count
DeeperShow the 1024→10 example concretely.