Trim a Binary Search Tree
Cut away every node whose value falls outside a range while keeping the tree ordered. The visual prunes subtrees and reattaches surviving children to their parents.
Cut away every node whose value falls outside a range while keeping the tree ordered. The visual prunes subtrees and reattaches surviving children to their parents.