Big O Notation
Last updated
Was this helpful?
Last updated
Was this helpful?
Big O represents the running time as a function of the size of the input (N).
We simplify to just the highest order term, and ignore constant coefficients of N.
Examples:
Formal definition:
Basically: f(n) worst case is g(n), so f(n) will be the same or faster than g(n).
An example: