0938. Range Sum of BST
https://leetcode.com/problems/range-sum-of-bst
Description
Given the root node of a binary search tree and two integers low and high, return the sum of values of all nodes with a value in the inclusive range [low, high].
Example 1:

Example 2:

Constraints:
The number of nodes in the tree is in the range
[1, 2 * 104].1 <= Node.val <= 1051 <= low <= high <= 105All
Node.valare unique.
ac
Last updated
Was this helpful?