Python Binary Search Tree || Beats 92% ||
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\n# Definition for a binary tree node.\n# class TreeNode:\n#     def __init__(self, val=0, left=None, right=None):\n#         self.val = val\n#         self.left = left\n#         self.right = right\nclass Solution:\n    def rangeSumBST(self, root: Optional[TreeNode], low: int, high: int) -> int:\n        def inOrderTraversal(node):\n            nonlocal total_sum\n            if not node:\n                return\n            if low <= node.val <= high:\n                total_sum += node.val\n            if node.val > low:\n                inOrderTraversal(node.left)\n            if node.val < high:\n                inOrderTraversal(node.right)\n\n        total_sum = 0\n        inOrderTraversal(root)\n        return total_sum\n```
['Binary Search Tree', 'Python3']