Big O with Examples

Big O notation is a way to talk about the time or resource complexity of an algorithm. It’s commonly used to describe worst, best, and average cases while comparing one algorithm to others. Since algorithms with less complexity finish faster that those with high complexity they are more desirable. The expression O(x) pronounced “big-O of x” is used to symbolically express the asymptotic behavior of a given function. Specifically when n is an integer that tends to infinity and x is a continuous variable tending to some limit....

April 4, 2022