Exam-style question
Try this first
Which use is specifically associated with a pre-order tree-traversal algorithm in the specification?.
- A.Outputting a binary search tree in ascending order
- B.Producing a postfix expression from an expression tree
- C.Copying a tree
- D.Emptying a tree
Model answer
What a good answer should say
- Copying a tree
Explanation
Why this works
The specified use of pre-order traversal is copying a tree. In-order is associated with ascending output from a binary search tree, while post-order is associated with postfix conversion and emptying a tree.
Common mistake
No common mistake is linked to this question yet.
