August 2020
Intermediate to advanced
508 pages
11h 53m
English
In the previous chapter, you learned how to write recursively and how to use recursion to solve some rather complex problems.
However, while recursion can certainly solve some problems, it can also create new ones if not used properly. In fact, recursion is often the culprit behind some of the slowest categories of Big O, such as O(2N).
The good news, though, is that many of these problems can be avoided. In this chapter, you’ll learn how to identify some of the most common speed traps found in recursive code and how to express such algorithms in terms of Big O. More important, you’ll learn the techniques to fix these problems.
Here’s some more good news: the techniques found in this chapter are actually pretty ...
Read now
Unlock full access