December 2023
Intermediate to advanced
504 pages
11h 43m
English
We now have some powerful analysis tools at our disposal. We can use Big O to broadly determine the efficiency of an algorithm, and we can also compare two algorithms that fall within one classification of Big O.
However, another important factor must be taken into account when comparing the efficiencies of two algorithms. Until now, we’ve focused on how fast an algorithm is in a worst-case scenario. Now, worst-case scenarios, by definition, don’t happen all the time. On average, most scenarios that occur are…well…average-case scenarios. In the next chapter, you’ll learn how to take all scenarios into account.
Read now
Unlock full access