Convert the following arithmetic expressions from infix to Reverse Polish
notation. Also show positions in Stack by possible diagram.
a. P * Q + R* S + T* U
b. A * B + A * (B * D + C * E)
c. M + N * [O * P + Q * (R + S)]
a)
i)
(P + Q) *(R - X)
ii)
(A/B)-C
---
b)
i)
-**P-QRST
ii)
-*++ABCD/EF
---
C)
i)
MNPQRST-*/***
ii)
Answer
126
Explanation
Hence Answer is 126
Comments
Leave a comment