![]() There are two basic operations that you can perform on a binary search tree: The binary tree on the right isn't a binary search tree because the right subtree of the node "3" contains a value smaller than it. they have the above two propertiesĪ tree having a right subtree with one value smaller than the root is shown to demonstrate that it is not a valid binary search tree Both subtrees of each node are also BSTs i.e.All nodes of right subtree are more than the root node.All nodes of left subtree are less than the root node. ![]() The properties that separate a binary search tree from a regular binary tree is
0 Comments
Leave a Reply. |