Binary Search Tree (BST)
By: Sam Avramov
Things to Know About the Binary Search Tree:
- Rules for a BST: In general, a BST follows the basic rules that the left sub-child of each node is less than the node, and the right sub-child of each node is greater than the node.
- Use Cases for a BST: BSTs are often used to maintain sorted data, and to retrieve it in an efficient manner.
- Average Time Complexities of a BST: In a BST, searching, deleting, and inserting typically run in O(log N) time, but the worst case run-time complexity is O(N) in an unbalanced BST.
Here is a reference page for Binary Search Trees:
Link