Binary Search Tree : Lowest Common Ancestor

  • + 0 comments

    that's very brilliant.

    but i tried tracing the path from root to key1 and taken this path into a queue. did the same for key2 and returned the last common integer among the two queues.

    complex right?