A binary tree structure built to automatically rebalance its structure when nodes become out of balance, in order to improve search times.
This program implements various classes and functions to facilitate the tree's functions.
- Templated BinarySearchTree class holds the standard functions of a binary tree.
- Templated BinaryTreeNode class holds format for tree nodes.
- Constructor and destructor that build and delete tree objects on command.
- findParentOrDuplicate function to find insertion points in the tree, or locate an existing item in the tree.
- Insert and remove functions to add and subtract items from tree.
- Rebalance functions to handle various cases of off-balance after insertion/deletion.
- Search function to locate items within the tree.
- Language: C++
- IDE: Visual Studio
Compilation instructions are included in comment header of main file.