postfix to infix:
5 x y - / x y + 3 ^ 7 / +
STEP
5 x y - /
A) 5xy-/ = 5 (x-y)/ = (5 / (x-y))
x y +
B) x y + = (x + y)
(x+y) 3 ^
B.1) (x + y) 3 ^ = ((x + y) ^ 3 )
Now, (5 / (x-y)) ((x + y) ^ 3 ) 7 / +
= (5 / (x-y)) (((x + y) ^ 3 )/7 ) +
= (5 / (x-y)) + (((x + y) ^ 3 )/7 )
POSTFIX and PREFIX are expression in which no brackets are used. Precedence of operator are decided in order of there appearance in expression, So to evaluate expression no need to search next operation to perform- FAST .
While in INFIX expression precedence of operators are overwritten by brackets. hence brackets are there in infix expression- Need to search which operation to perform e.g. A+B%D - hence SLOW.
That is the reason conversion are useful in computer science.