What is the result of a post-order traversal on a binary tree with nodes 1, 2, and 3, where 1 is the root, 2 is the left child, and 3 is the right child?

Practice Questions

1 question
Q1
What is the result of a post-order traversal on a binary tree with nodes 1, 2, and 3, where 1 is the root, 2 is the left child, and 3 is the right child?
  1. 1, 2, 3
  2. 2, 3, 1
  3. 3, 2, 1
  4. 1, 3, 2

Questions & Step-by-step Solutions

1 item
Q
Q: What is the result of a post-order traversal on a binary tree with nodes 1, 2, and 3, where 1 is the root, 2 is the left child, and 3 is the right child?
Solution: In post-order traversal, we visit the left child, then the right child, and finally the parent. Thus, the output is 2, 3, 1.
Steps: 0

Related Questions

Soulshift Feedback ×

On a scale of 0–10, how likely are you to recommend The Soulshift Academy?

Not likely Very likely