What is the minimum number of nodes a general binary tree must have so that its Pre-order and Post-order traversals are ambiguous (i.e., more than one valid tree can be constructed)?
B
Step-by-Step Solution
Key idea: Ambiguity in Pre-order and Post-order reconstruction occurs when a node has exactly one child, because the sequences cannot distinguish if it is a left or right child.
Step 1: For a tree with 1 node, Pre-order and Post-order are identical and uniquely define the tree.
Step 2: For a tree with 2 nodes (a root and one child), Pre-order is [Root, Child] and Post-order is [Child, Root]. The child could be either the left or right child of the root. This creates ambiguity.
Step 3: Therefore, the minimum number of nodes required to create this ambiguity is 2.
Answer: The minimum number of nodes is 2.