Any code of your own that you havenít looked at for six or more months might as well have been written by someone else. Eaglesonís Law

Insert and Delete in BST

Language Java | Level Intermediate | Category Data structure | September 6, 2015 7:51 am


Data structure Description

Write a program to insert an item to the binary search tree and delete the item from binary search tree. If the node value is less than or equal to the parent node, insert the node to left the tree. If the node value is greater than or equal to the parent node, insert the node in the right subtree.


Output

   					 

All Binary Tree Values: 1 2 3 4 5  
All Binary Tree Values after remove: 1 2 4 5  

				    

Comments


No comments available!

Please login to add comments.