938. 二叉搜索树的范围和
https://leetcode-cn.com/problems/range-sum-of-bst/
class Solution(object):
def rangeSumBST(self, root, L, R):
def dfs(node):
if node:
if L <= node.val <= R:
self.ans += node.val
if L < node.val:
dfs(node.left)
if node.val < R:
dfs(node.right)
self.ans = 0
dfs(