(205 Views)

Infix notation is a type of notation in which arithmetic expressions are written in a manner such that the operators appear in between the operands.

Prefix notation is a type of notation in which arithmetic expressions are written in a manner such that the operands appear after operators. Let's see how to convert Prefix to Infix.

Let's take an example to understand *a+bc,

- Reading from right to left, we scan the operands 'c' 'b' respectively and push it into the the stack.
- '+' is scanned and operands 'c', 'b' are popped and concatenated in form of b+c
- 'a' is then pushed into the stack.
- '*', is encountered and 'a' and string 'b+c' is popped and concatenated to give a string a*(b+c)
- Postfix form is obtained: a*(b+c)

You might be interested in this too.:

0 UpvotesUpvote |
0 DownvotesDownvote |

- Tower of Hanoi Algorithm in C [192 Views]
- Bellman Ford Algorithm in Python [1177 Views]
- Python program to Print Prime Number from 1 to n [693 Views]
- Infix to Prefix notation Algorithm and Flowchart [402 Views]
- How to Check if Android Device has NFC Feature programmatically in Android Studio [789 Views]

- How To Win Ludo King Game Every Time [22467 Views]
- Algorithm to find whether number is Armstrong Number or Not [21742 Views]
- Jio Phone hang on LOGO problem Solution - Hard Reset Jio Phone [14806 Views]
- Knuth-Morris-Pratt (KMP) Substring Search Algorithm with Java Example [14296 Views]
- FlowChart and Algorithm to find Whether a Number is Even or Odd [10852 Views]