Write a program to evaluate infix expressions. An infix expression looks like th
ID: 3562871 • Letter: W
Question
Write a program to evaluate infix expressions. An infix expression looks like the following:
9 * (5 - 4) + 2 / 6
This program must first convert the infix expression to a postfix expression, and then evaluate the postfix expression. A postfix expression for the above infix expression looks like the following:
9 5 4 - * 2 6 / +
For this assignment you will need to implement and apply one stack to convert from infix to postfix, and implement and apply a second stack to evaluate the postfix expression. Make sure the program has 1 header file (.h) 2 sources files (.c)
Note : Create a single program only, which combines both exercises. Also, be sure to allow the user to continue to enter infix expressions until they want to quit the program.
Please write it on C programing and able to run on Visual Studio 2012.
Explanation / Answer
Algorithm infix2postfix(infix exp<b></b>ression string, postfix exp<b></b>ression string)
02 {Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.