Binary Search Tree

0 comments

Implement a Data Structure in C++ that fulfills the requirements of both the Set and Map Abstract Data Types (ADTs). Achieve this through multiple inheritances.

Using these files, develop an original source code for the BinarySearchTree.h methods. It must deliver a Binary Search Tree that correctly performs the actions specified in the two interface files. For example, every Set must provide a ‘contains’ operation, you ust develop this code in the own BinarySearchTree.h file.

The files Set.h and Map.h define the exhaustive set of methods you must implement. The file BinarySearchTree.h has a boiler-plate already built with the required functions, so you only provide their unique code.

The BinarySearchTree must demonstrate O(log n) behavior for get, insert, and remove when working with a balanced number sequence. The timing for this structure will be unavoidably deplorable when inserting a series in-order, however, you are under no expectation to solve that problem. This data structure will break down with in order key sequence insertions, and that is expected.

Do not use 3rd party external libraries or data structures.

About the Author

Follow me


{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}