Binary tree sum check for a path
For given a sum check whether there exists a path from root to any of the nodes.
Source Code:
Github: BinaryTreeNodeSumPathFinder.java
Output:
1 / \ / \ / \ / \ / \ / \ / \ / \ 2 3 / \ / \ / \ / \ 4 5 / / / / 8 6 \ 7 Diameter is : 14 Is path exists with sum (8): true Is path exists with sum (100): false