You are given the root of a binary tree and an integer target_sum.\n\nYour task is to determine if there exists a root-to-leaf path in the binary tree such that the sum of all node values along that path equals target_sum.\n\nNote that:\n* A leaf is defined as a node with no children.\n* A root-to-leaf path is a sequence of nodes starting from the root node and ending at any leaf node in the tree.\n\nReturn True if such a path exists, otherwise return False.
target_sum = 22
True
The path 5 -> 4 -> 11 -> 2 has a sum of 5 + 4 + 11 + 2 = 22.
target_sum = 5
False
No root-to-leaf path sums to 5. The paths are 1 -> 2 (sum 3) and 1 -> 3 (sum 4).
target_sum = 1
True
The only root-to-leaf path is 1, which sums to 1.
target_sum = 22
True