Formal Definition

Big-Theta Notation

Keep in note that there must be the same value of for both ceiling and growth functions.

Common Big-O Functions

(and where they are found)

Time ComplexityFound In
Running time independent of input.
Typical for “divide and conquer” solutions, for example, lookup in a balanced search tree.
Linear. When each input element must be processed once.
Each input element processed once and processing involves other elements too, for example, sorting.
Quadratic, cubic. Processing all pairs (triples) of elements.
Exponential. Processing all subsets of elements.