Binary Search Tree (BST)

A Binary Search Tree (BST) is a binary tree where each node has a comparable key, and satisfies the binary search property: all keys in the left subtree are smaller, and all keys in the right subtree are larger.

Key Properties

Common Operations

  1. Insertion: Add a new node at the correct position based on key value.
  2. Search: Traverse left or right depending on key comparison.
  3. Deletion: Remove a node and maintain BST structure.

Example BST Structure:

Binary Search Tree diagram

Learn more at Wikipedia: Binary Search Tree .