What Is Big O Notation
· Category: Tech Fundamentals
Short answer
Big O Notation formally describes the upper bound of an algorithm's growth rate. It expresses the worst-case scenario as input size approaches infinity.
How it works
Common classes include O(1) constant, O(log n) logarithmic, O(n) linear, O(n log n) linearithmic, O(n^2) quadratic, and O(2^n) exponential. We drop constants and lower-order terms.
Example
An algorithm with runtime 3n^2 + 2n + 5 is simplified to O(n^2) because the quadratic term dominates at large scales.
Why it matters
Big O provides a common language for discussing algorithm efficiency. It helps teams choose scalable solutions during code reviews and system design.