Code for problem "Validate Binary Search Tree".