O'Reilly logo

Everyday Data Structures by William Smith

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Summary

In this chapter we learned about tree data structures, and how they differ from tree data types. We took the time to examine the terminology associated with trees including a visual representation of tree data structures. Next we evaluated the most common operations when working with trees and their complexity cost. Following this we created our own simple binary tree data structure class from scratch, and discussed how the recursive operations are used to traverse the tree. We examined the meaning of recursion and how to write recursive functions of your own using the Fibonacci sequence as an example of this process. Finally, we examined the various ways that tree data structures can be traversed depending on how the nodes in the tree ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required