Inside every large program, there is a small program trying to get out. C.A.R. Hoare

PostfixtoInfix

Language Java | Level Intermediate | Category Data structure | August 30, 2015 2:14 pm


Data structure Description

Infix notation is the notation commonly used in arithmetical and logical formulae and statements. Postfix also known as Reverse Polish Notation is a notational system where the operation or function follows the arguments.

Write a program convert from Postfix notation to infix notation using the stack.

Example
Postfix: 5 3 + 12 * 3 /
Infix (5 + 3) * 12 / 3


Output

   					 

Postfix Expression: abc*+
Infix Expression: (a+(b*c))

				    

Comments


No comments available!

Please login to add comments.