Lab 05 DSA
Lab 05 DSA
Write a program to create the binary tree above and perform the following operations
discussed:
a) Print out the expression in the prefix form (pre-order trversal).
b) Print out the expression in the infix form (in-order trversal).
c) Print out the expression in the postfix form (post-order trversal).
d) Compute the value of the postfix expression.
Suggestion:
You should reuse the solution to Problem 1 in Lab 3.