Tag Archives: interview questions to find second largest element in a BST

Second largest element in Binary Search Tree

Second largest element in Binary Search Tree (BST). Problem statement to find the second largest element in a Binary Search Tree (BST) Given a binary search tree, determine its second largest element. In inorder traversal, the second last element is the second largest while in reverse inorder traversal, the second element is second largest element. Example:… Read More »