ISRO | ISRO CS 2020 | Question 46
The post-order traversal of a binary tree is ACEDBHIGF. The pre-order traversal is
(A) ABCDEFGHI
(B) FBADCEGIH
(C) FABCDEGHI
(D) ABDCEFGIH
(E) None of these
Answer: (E)
Explanation: We can not create binary tree uniquely with either pre-order or/and post-order. We strictly need in-order of binary tree with either pre-order or/and post-order.
So, option (E) is correct.
Note that if given tree was Binary search tree (BST), then we were able to create BST uniquely, as in-order of BST is always sorted order.
Please Login to comment...