# left to right, pre-order depth first tree search, recursive. O(n) time/space def depthFirstSearchRec(root): if root == None: return print(root) depthFirstSearch(root.left) depthFirstSearch(root.right)