give root binary search tree low high boundary low high trim tree element lie low high trimming tree change relative structure element remain tree ie node descendant remain descendant it prove unique answerreturn root trim binary search tree note root change depend give bound Example 1input root 102 low 1 high 2output 1null2example 2input root 304null2nullnull1 low 1 high 3output 32null1 ConstraintsThe number nod tree range 1 1040 Nodeval 104The value node tree uniqueroot guarantee valid binary search tree0 low high 104