Skip to content

Latest commit

 

History

History

Check If Two Trees are Identical or Not

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Two trees are identical when they have same data and arrangement of data is also same.

To identify if two trees are identical, we need to traverse both trees simultaneously, and while traversing we need to compare data and children of the trees.