• edited by
1,517 views
1 1 vote
A rooted tree with 8 nodes has its nodes [1.....8] in preorder.When the tree is traversed in postorder.....nodes visited are

{3,5,4,2,7,8,6,1}.

Draw a  tree for it.

How to solve .....someone please explain?

1 Answer

Position:
Show:

Related questions

10 10 votes
1 1 answer
351
351 views
GO Classes asked Jul 28
351 views
A binary tree has:$1000$ nodes in the left subtree $100$ nodes in the right subtreeHow many nodes are processed before the root in preorder, inorder, and postorder traver...
7 7 votes
1 1 answer
211
211 views
GO Classes asked Jul 13
211 views
Which of the following functions correctly returns the total number of nodes in a binary tree rooted at $\texttt{t}$?int tree_size(TreeNode *t) { if (t == NULL) return 0;...
11 11 votes
1 1 answer
264
264 views
GO Classes asked Jul 11
264 views
Which of the following can be the number of nodes in a complete binary tree?$2$ $5$ $7$ $8$