Function Growth and Big-O Notation

One of the most important aspects of algorithms is how quickly they grow. The quicker the growth, the better.

Here is a list of function types in order of their growth:

  1. Constant functions
  2. Logarithmic functions
  3. Linear functions
  4. Linearithmic functions
  5. Polynomial functions
  6. Exponential functions

Big-O Notation is a way to describe the growth, complexity and performance of an algorithm. The strongest notation we can make about binary search is that it runs in O(lgn) time. Because big-O notation gives only an asymptotic upper bound certain technical generalizations can be made and will be considered correct. Big O specifically calculates the worst-case scenario, and can be used to describe the run time or the space required by an algorithm.

Leave a comment