0% found this document useful (0 votes)
24 views

Treetravout

The document discusses different tree traversal methods including inorder, preorder, and postorder. The user is prompted to enter the number of elements in a tree and is then given options to view the traversal of those elements using different traversal methods and output the results.

Uploaded by

shameedp
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views

Treetravout

The document discusses different tree traversal methods including inorder, preorder, and postorder. The user is prompted to enter the number of elements in a tree and is then given options to view the traversal of those elements using different traversal methods and output the results.

Uploaded by

shameedp
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 1

TREE TRAVERSAL

OUTPUT:

Ente r the number o f e lements i n the t5ree :

The e lements a re9: 4 3 8 45

The Poss ib le opera t i ons a re :

1 . Ino rde r 2 .P reo rde r 3 .Pos to rde r4 .Ex i t

Ente r your cho i ce : 1

I no rde r Trave rsa l o f the g iven t ree


3 4 8 9 45

Ente r your cho i ce : 2

Preo rde r Trave rsa l o f the g iven t ree


9 4 3 8 45

Ente r your cho i ce : 3

Pos to rde r Trave rsa l o f the g iven t ree


3 8 4 45 9

Ente r your cho i ce : 4

1 | Pa g e t r e e t r a v. - o / p

You might also like