1.

The postfix expression abc+de/*- is equivalent to which of the following infix expression?(a) abc+-de*/(b) (a+b)-d/e*c(c) a-(b+c)*(d/e)(d) abc+*-(d/e)My enquiry is from Application of Stacks in chapter Application of Stacks of Data Structures & Algorithms II have been asked this question during a job interview.

Answer»

Right answer is (C) a-(b+c)*(d/e)

Easy explanation - Given POSTFIX expression : abc+de/*-

INFIX ⇒ a(b+c)(d/e)*-

⇒ a(b+c)*(d/e)-

⇒ a-(b+c)*(d/e)

Hence, CORRECT choice is a-(b+c)*(d/e).



Discussion

No Comment Found

Related InterviewSolutions