Convert the following infix expressions to their postfix equivalents:
(a) A – B + C
(b) A * B + C / D
(c) (A – B ) + C * D / E – C
(d) (A * B) + (C / D) – ( D + E)
(a) A – B + C
Answer:
A – B C+
(b) A * B + C / D
Answer:
A B * C D/+
(c) (A – B ) + C * D / E – C
Answer:
A – B C D * E – C/+
(d) (A * B) + (C / D) – ( D + E)
Answer:
A B* C D/ – D E++
Comments
Leave a comment