Consider the following expression tree. Root * has left child + and right…

NVS Computer Science / IT Teacher Recruitment · 2022 · PGT Computer Science · 15 Dec 2022 · Shift 2 · Computer Science or Information Technology

Consider the following expression tree. Root * has left child + and right child g; + has left child * and right child f; the lower * has children d and e. Preorder and post-order traversal of the tree will result into ________ and __________ expressions, respectively.

  1. A.

    d * e + f * g, d e * f + g *

  2. B.

    * + * d e f g, d e * f + g *

  3. C.

    * + * d e f g, d * e + f * g

  4. D.

    * + * d e f g, d e f g * + *

Attempted by 10 students.

Sign up free to check your answer

Sign up free

Explore the full course: Rssb Senior Computer Instructor

Loading lesson…