Fibonacci Search
Partitions the range using Fibonacci numbers. Because it computes indices with only addition and subtraction — no division — it can beat binary search on hardware where division is expensive or where cache-friendly access matters.
01Fibonacci Search
Explore How It WorksStarting Fibonacci search. It carves the range by Fibonacci numbers, choosing each probe with additions and subtractions only — no division.
The first probe is index 4, holding 45. Compare it with the target 89.
45 is smaller than 89. Keep only the right side and step the Fibonacci numbers down one.
The next probe is index 7, holding 78.
78 also falls short of 89. Move right again and shrink the range further.
This probe lands on 98, at the end of the array.
98 is larger than 89. The target is to the left, so step the Fibonacci numbers down two and cut the range sharply.
The probed slot holds 89 — a match, on the fourth probe.
Search complete · 89 sits at index 8. It replaces binary search where division is expensive, as on embedded hardware.
02 Understand It Simply
For EveryoneDivides the range at Fibonacci numbers, narrowing it with additions and subtractions only, never a division.
Splits the range with the Fibonacci sequence.
It uses only addition and subtraction (no division), which helps on certain hardware.
- –Environments where division is costly
- –cache-friendly access
03 Python Implementation
A clean, readable reference implementation of the core logic of Fibonacci Search.
04 Frequently Asked Questions
FAQWhat is Fibonacci Search?+
Partitions the range using Fibonacci numbers. Because it computes indices with only addition and subtraction — no division — it can beat binary search on hardware where division is expensive or where cache-friendly access matters.
What is the time complexity of Fibonacci Search?+
The time complexity of Fibonacci Search is O(log n). Follow the step-by-step visualization to see exactly why.
Where is Fibonacci Search used?+
Environments where division is costly, cache-friendly access.
What's a simple analogy for Fibonacci Search?+
Divides the range at Fibonacci numbers, narrowing it with additions and subtractions only, never a division.
