Available question text
Given a BST and bounds [low, high], remove all nodes with values outside the interval while preserving the relative parent–child structure of remaining nodes; exploit the BST ordering to skip whole left or right subtrees and return the (possibly changed) new root.
Related questions
Continue with questions that share topics or the same question type.
- Balance a Binary Search Tree
Coding
- Binary Search Tree Iterator
Coding
- Binary Search Tree Iterator II
Coding
- Binary Search Tree to Greater Sum Tree
Coding · Binary Search Tree · Binary Tree · Depth-First Search
Sources · 1 reference
These records explain where the question appears. A company tag or candidate report does not guarantee a future interview question.
Hello Interview · 1 record
No company association
Leetcode 669. Trim a Binary Search Tree
Reported date not specified · 0 source reports
Source snapshot: Nov 12, 2026
View source