Java Reference
In-Depth Information
Figure 14-3. Output from the FractalTree Program
Summary
In this chapter, I explained the unusual but sometimes useful idea of working with items that refer to
themselves, known as recursion. In particular, you learned that:
•
Recursion occurs in human languages.
•
Recursion happens all the time (but we often don't notice it).
•
Recursive algorithms need stop conditions.
•
It's sometimes a good idea to avoid recursion.