Question: C++ A binary search tree (BST is a node-based binary tree data structure which has the following properties The left sub-tree of a node contains
A binary search tree (BST is a node-based binary tree data structure which has the following properties The left sub-tree of a node contains only nodes with keys less than or equal to the node's key The right sub-tree of a node contains only nodes with keys greater than or equal the node's key The left and right sub-trees must each also be a binary search tree 1) - Create an array, a vector or a linked list of student records (20+ records ) which are randomized and unsorted student records should include Student ID, Name, and a pointer pointing to 10 grades of the student. Display the unsorted list from above array, vector, or linked list. 2) - Create a binary search tree for the above list by using BST insert function. Display the binary search tree by using in-order traversal. (Your result should be a sorted result without using sort.) 3) Search two nodes (records) in the middle of the binary search tree and display the search result. 4) - Delete two nodes in the middle of the binary search tree. Display again the binary search tree by using in order traversal after the deletion (sorted result) .. 5) Repeat the above procedures for at least two sets of student records
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
