## Find the node with maximum value in a Binary Search Tree

Given a Binary Search Tree, the task is to find the node with the maximum value in a BST. For the above tree, we start… Read More »

- Binary Search Tree | Set 1 (Search and Insertion)
- AVL Tree | Set 1 (Insertion)
- A program to check if a binary tree is BST or not
- Binary Search Tree | Set 2 (Delete)
- Check if a given array can represent Preorder Traversal of Binary Search Tree
- Lowest Common Ancestor in a Binary Search Tree.
- Construct BST from given preorder traversal | Set 1
- Find k-th smallest element in BST (Order Statistics in BST)
- Sorted Array to Balanced BST
- Inorder Successor in Binary Search Tree
- K'th largest element in a stream
- Remove BST keys outside the given range
- Red-Black Tree | Set 2 (Insert)
- Two nodes of a BST are swapped, correct the BST
- Find a pair with given sum in a Balanced BST
- Advantages of BST over Hash Table
- Binary Tree to Binary Search Tree Conversion
- Find the node with minimum value in a Binary Search Tree
- Construct BST from given preorder traversal | Set 2
- Sorted Linked List to Balanced BST
- Total number of possible Binary Search Trees and Binary Trees with n keys
- K'th Largest Element in BST when modification to BST is not allowed
- Inorder predecessor and successor for a given key in BST
- Optimal Binary Search Tree | DP-24
- Find postorder traversal of BST from preorder traversal
- Merge two BSTs with limited extra space
- Overview of Data Structures | Set 2 (Binary Tree, BST, Heap and Hash)
- Find the largest BST subtree in a given Binary Tree | Set 1
- Construct all possible BSTs for keys 1 to N
- Convert a normal BST to Balanced BST

Given a Binary Search Tree, the task is to find the node with the maximum value in a BST. For the above tree, we start… Read More »

Given a Binary Search Tree. The task is to find the sum and product of maximum and minimum value of tree. For the above tree,… Read More »

Given an array of integers, the task is to find the sequence in which these integers should be added to an AVL tree such that… Read More »

Given the height of an AVL tree ‘h’, the task is to find the minimum number of nodes the tree can have. Examples : Input… Read More »

Given a binary search tree. The task is to print all even nodes of the binary search tree. Examples: Input : 5 / \ 3… Read More »

Given a Binary Search Tree (BST) and a range [min, max], remove all keys which are inside the given range. The modified tree should also… Read More »

Given postorder traversal of a binary search tree, construct the BST. For example, 1. If the given traversal is {1, 7, 5, 50, 40, 10},… Read More »

A recursive approach to insert a new node in a BST is already discussed in the post: Binary Search Tree | SET 1. In this… Read More »

Given Q queries. The queries are of three types and are described below: Add the number num to the list. Remove the number num from… Read More »

Given the root nodes of the two binary search trees. The task is to print 1 if the two Binary Search Trees are identical else… Read More »

Given two arrays which represent two sequences of keys that are used to create BSTs. Imagine we make a Binary Search Tree (BST) from each… Read More »

Given a BST and a number. The task is to check whether the given number is equal to the sum of all the node from… Read More »

Given a BST and a key Node, find the total sum in BST, except those Node which are adjacent to key Node. Examples: Recommended: Please… Read More »

Given a preorder traversal of a BST. The task is to find the number of elements less than root. Examples: Input: preorder[] = {3, 2,… Read More »

Consider a problem where same elements are likely to be searched again and again. Implement search operation efficiently. Examples : Input : arr[] = {12… Read More »