Binary Search Tree (BST) is a binary tree data structure with the following properties,

  1. The left sub-tree of a node has nodes with keys lesser than the node’s key
  2. The right sub-tree of a node has nodes with key greater than the node’s key
  3. Both the left sub-tree and the right sub-tree must be BSTs