Skip to content

Commit ef3c5bf

Browse files
authored
Update Lowest Common Ancestor of a Binary Tree - Leetcode 235.py
1 parent 9355100 commit ef3c5bf

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Lowest Common Ancestor of a Binary Tree - Leetcode 235.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,6 @@ def search(root):
1818

1919
search(root)
2020
return lca[0]
21+
22+
# Time Complexity: O(h) { here "h" is the height of the binary search tree }
23+
# Space Complexity: O(h) { here "h" is the height of the binary search tree }

0 commit comments

Comments
 (0)