Measuring programming progress by lines of code is like measuring aircraft building progress by weight. Bill Gates

Evaluate infix notation using Shunting-yard algorithm

Language Java | Level Intermediate | Category Data structure | August 30, 2015 1:06 pm

Data structure Description

The infix notation put operators in between the operands. The postfix notation put operators after their operands. Shunting-yard algorithm is a method for parsing mathematical expressions specified in infix notation.

Write a program to convert an infix expression to postfix expression using the shunting-yard algorithm.



Shunting Yard Algorithm to convert from Infix Expression to Postfix Expression

Enter infix expression : 1+2*3

Postfix expression : 123*+



No comments available!

Please login to add comments.