Tree Traversal/OOP
From charlesreid1
Contents
Notes
Goodrich Data Structures and Algorithms - Trees
As with prior chapters and topics in the two version of the Goodrich book, Python and Java, there is a difference in the treatment - and as before, I prefer the Python textbook's treatment, but I used Java as the language of implementation.
The common thread of both versions of this chapter, the Python and Java versions, is that the material becomes more advanced, incorporating object oriented principles alongside the data structure concepts. This allows simpler concepts learned in prior chapters to be made reusable, and connected to the more advanced concepts that can be found in places like the Collections framework.
Python
The Python treatment focuses on the "Template Method Pattern" - the idea that you can find a generalized computation mechanism that can be specialized for a particular application through a series of "hooks".
Java
The Java class concepts are focused more on the (frankly, nonsense) interfaces for Positions and Nodes, which ended up taking an excessive amount of time to properly implement, were quite confusing, etc. Waste of time. Hmm...
Flags
Trees Part of Computer Science Notes
Series on Data Structures Abstract data type: Trees/ADT Concrete implementations: Trees/LinkedTree · Trees/ArrayTree · SimpleTree
Tree Traversal Preorder traversal: Trees/Preorder Postorder traversal: Trees/Postorder In-Order traversal: Binary Trees/Inorder Breadth-First Search: BFS Breadth-First Traversal: BFT Depth-First Search: DFS Depth-First Traversal: DFT OOP Principles for Traversal: Tree Traversal/OOP · Tree Traversal/Traversal Method Template Tree operations: Trees/Operations Performance · Trees/Removal
Tree Applications Finding Minimum in Log N Time: Tree/LogN Min Search
Abstract data type: Binary Trees/ADT Concrete implementations: Binary Trees/LinkedBinTree · Binary Trees/ArrayBinTree Binary Trees/Cheat Sheet · Binary Trees/OOP · Binary Trees/Implementation Notes
|