Algo to find if two Binary Trees are structurally equivalent
Anonymous
this can be done with just 2 pointers , 1 for each binary tree. make any order traversal in first tree and see weather the same traversal is possible in 2nd tree irrespective of the values present in it... if any of the condition violates, return false... if both reaches NULL at the same time.... return true..
Check out your Company Bowl for anonymous work chats.