0% found this document useful (0 votes)
113 views1 page

Infix to Prefix/Postfix Guide

This document provides examples of infix, prefix, and postfix notation for mathematical expressions. There are 25 examples shown with the infix expression, equivalent prefix expression, and equivalent postfix expression. The examples cover a range of mathematical operations including exponents, multiplication, division, addition, subtraction, and order of operations.

Uploaded by

sandhya sharma
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
113 views1 page

Infix to Prefix/Postfix Guide

This document provides examples of infix, prefix, and postfix notation for mathematical expressions. There are 25 examples shown with the infix expression, equivalent prefix expression, and equivalent postfix expression. The examples cover a range of mathematical operations including exponents, multiplication, division, addition, subtraction, and order of operations.

Uploaded by

sandhya sharma
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

10CS35-Data Structure with C

Assignment on Infix to Prefix, Postfix Conversion

S.No Infix Expression Prefix Expression Postfix/Suffix Expression


1. (B^2-4*A*C)^(1/2) ^-^B2-**4AC/12 B2^4A*C*-12/^
2. (A+B-C)*(E/F)-(G-H/I) -*++ABC/EF/-GHI AB+C-EF/*GHI/--
3. ((A/(B-C+D))*(E-A)*C) **/A+-BCD-EAC ABC-D+/EA-*C*
4. (3*4^6+(2*(5/6)^8)) +*3^46^*2/568 346^*256/8^*+
5. ((P%Q)/A*B^C)+(R-S%U)+W^Z ++/%PQ*A^BC-R%SU^WZ PQ%A/BC^*RSU%-+WZ^+
6. 1-4^3+7*(9^1/5)-2 -+-1^43*7^9/152 143^-791^5/*+2-
7. ((3*4)^6+2*(5/6)^8) +^*346^2^/568 34*6^256/8^*+
8. (P%Q)/A*B^C+(R-S%U)+W^Z ++*/%PQA^BC-R%SU^WZ PQ%A/BC^*RSU%-+WZ^+
9. 1-4^3+7*(9^1/5)-2 -+-1^43*7/^9152 143^-791^5/*+2-
10. (M*N)-X^Y^Z*(A+B-C/P*Q^R)/D -*MN/*^X^YZ-+AB*/CP^QRD MN*XY^Z^AB+CP/QR^*-*D/-
11. ((A^B)^C^M*W/X)^Y^Z ^/*^^AB^CMWX^YZ AB^C^M^W*X/Y^Z^
12. A/B^C+D*E–A*C -+/A^BC*DE*AC ABC^/DE*+AC*-
13. A^C+D-E*(X^Y*Z) -+^ACD*E*^XYZ AC^D+EXY^Z**-
14. (A%D)^C*E+X-Y*(A^B) -+*^%ADCEX*Y^AB AD%C^E*X+YAB^*-
15. A+B-(C*D^E)*X+Y +-+AB**C^DEXY AB+CDE^*X*-Y+
16. ((A^B*C)^I*(D-Z)/M+N) +/*^*^ABCI-DZMN AB^C*I^DZ-*M/N+
17. A*B+C^D +*AB^CD AB*CD^+
18. A^C-D*E -^AC*DE AC^DE*-
19. A+(C^D+E) +A+^CDE ACD^E++
20. A*(B+C)/D /*A+BCD ABC+*D/
21. A*B+(C-D/E) +*AB-C/DE AB*CDE/-+
22. A*(B+C)/D-G -/*A+BCDG ABC+*D/G-
23. ((A/D+C)*(X^Y)) *+/ADC^XY AD/C+XY^*
24. A+B*C-D -+A*BCD ABC*+D-
25. A*B-C+D +-*ABCD AB*C-D+

Prof. A. Syed Mustafa, HKBKCE, Bangalore

You might also like