+1 vote
in Data Structures & Algorithms I by (110k points)
Which of the following statement is incorrect with respect to infix to postfix conversion algorithm?

(a) operand is always placed in the output

(b) operator is placed in the stack when the stack operator has lower precedence

(c) parenthesis are included in the output

(d) higher and equal priority operators follow the same condition

My question is from Application of Stacks in division Application of Stacks of Data Structures & Algorithms I

This question was posed to me during a job interview.

1 Answer

+1 vote
by (408k points)
selected by
 
Best answer
Right choice is (c) parenthesis are included in the output

The best I can explain: Parentheses are not included in the output. They are placed in the operator stack and then discarded.

Related questions

Welcome to TalkJarvis QnA, a question-answer community website for the people by the people. On TalkJarvis QnA you can ask your doubts, curiosity, questions and whatever going in your mind either related to studies or others. Experts and people from different fields will answer.

Categories

...