A Big-O Drill
Explore the fundamentals of Big-O notation and running-time analysis. This lesson teaches you to prove asymptotic upper bounds of functions and estimate running times of code segments using formal methods and practical examples.
We'll cover the following...
We'll cover the following...
An easy warm up
Claim: is .
To prove this, we want to find positive constants and for which
One way to approach a problem
Suppose we want to show that is .
Demonstration: To do this, we begin by showing an upper bound on each term of the form , for some constant .
For ,
...