iphone app# pets - 心有所宠
j*y
1 楼
Find the common ancestor of two nodes in a tree. The tree is not a binary
tree strictly in that the left node is less than the right node. Also this
solution should work for trees with three or four children. Provide both a
recursive and iterative solution.
tree strictly in that the left node is less than the right node. Also this
solution should work for trees with three or four children. Provide both a
recursive and iterative solution.