Implement the CheckBSTValidity() function in the BSTChecker class in the BSTChecker.h file. The function takes the tree's root node as a parameter and returns the node that violates BST requirements, or nullptr if the tree is a valid BST.
A violating node will be one of three things:
A node in the left subtree of an ancestor with a lesser key
A node in the right subtree of an ancestor with a greater key
A node with the left or right member variable pointing to an ancestor
The given code in main.cpp reads and parses input, and builds the tree for you. Nodes are presented in the form (key, leftChild, rightChild), where leftChild and rightChild can be nested nodes or "None". A leaf node is of the form (key). After parsing tree input, the BSTChecker::CheckBSTValidity() function is called and the returned node's key, or "No violation", is printed.