Open In App
Related Articles

Data Structures | Tree Traversals | Question 7

Improve Article
Improve
Save Article
Save
Like Article
Like

Which traversal of tree resembles the breadth first search of the graph?
(A) Preorder
(B) Inorder
(C) Postorder
(D) Level order


Answer: (D)

Explanation: Breadth first search visits all the neighbors first and then deepens into each neighbor one by one. The level order traversal of the tree also visits nodes on the current level and then goes to the next level.

Quiz of this Question

Last Updated : 28 Jun, 2021
Like Article
Save Article
Similar Reads
Related Tutorials