Your task is to complete the function Paths() that takes the root node as an argument and return all the possible path. (All the path are printed '#' separated by the driver's code.)
Note: The return type cpp: vector java: ArrayList> python: list of list
Expected Time Complexity: O(N). Expected Auxiliary Space: O(H). Note: H is the height of the tree.
Note: The Input/Ouput format and Example given, are used for the system's internal purpose, and should be used by a user for Expected Output only. As it is a function problem, hence a user should not read any input from the stdin/console. The task is to complete the function specified, and not to write the full code.