Find the next larger node and write down code
Anonym
private static BSTNode getTheNextLargerElement(BSTNode node, int x) { if(node == null) return null; BSTNode returned; if(node.info > x) { returned = getTheNextLargerElement(node.left, x); if(returned == null) { return node; } return returned; } return getTheNextLargerElement(node.right,x); }