Kuldeep Patidar
Kuldeep Patidar

Reputation: 3

Can preorder, postorder and in order traversals be beneficial to a real time application?

Sequences ["A", "B", "C", "D", "E", "F"] (preorder) and ["B", "A", "E", "D", "F", "C"] (inorder)

What can relate to a real-life example application?

Upvotes: 0

Views: 105

Answers (1)

Linux Geek
Linux Geek

Reputation: 967

Postorder: Used to delete a tree.

Inorder: Used to print data in ordered (ascending) fashion.

Preorder: Used to create a copy of the tree.

Upvotes: 0

Related Questions