28: Expression Conversion using Stack | Infix to Postfix

Опубликовано: 28 Сентябрь 2024
на канале: ezycode
310
7

CSE/IT/MCA and BCA Free Placement Series
In this video you will learn about expression conversion using stack method. I have covered about the conversion of Infix notation to prefix notation using stack method with example.

It will help the students of BCA, MCA and B.Tech Students for the university examination as well as placement preparation.

We can represent the expression in three different way namely Infix, prefix and postfix notation.

stack plays an important role for mathematical expression evaluation. In this video, I have covered basics of these three representation style.
these are as follows:

1. Infix Notation
2. Prefix Notation
3. Postfix Notation


also, i have discussed that how to create an expression tree. I have taken som mathematical expression to create an expression tree with example.


At the end you will get clear concept of expression conversion from infox to prefix using stack method.


Topic covered:
1. Infix, Prefix and Postfix Representation
2. Overview of stack PUSH and POP
3. Infix to Postfix conversion using stack
4. summary

Preorder Traversal gives Prefix Notation
Inorder Traversal gives Infix Notation
Postorder Traversal gives Postfix Notation


The basic operations and terminology used in stack is
1. PUSH : Insertion of an item in the stack is called PUSH
2. POP : Deletion of an item from the stack is called POP
3. Overflow: if the stack is full, even we will try to insert an item in the
stack then overflow occurs.

4. Underflow: If the stack is empty even we will try to remove an item from stack then underflow occurs.

5. LIFO : (Last In First Out) The item which is inserted at last will be removed at first.

6. Stack has only one open end.
7. Insertion and deletion of item takes place from one end.
Facebook Ezycode:
-------------
  / ursmartcoder  

Facebook Chandra Mani:
-------------
  / cmofindia  

#ezycode
#stack
#datastructures
#dsa
#clanguage