COMPILER DESIGN

SYNTAX ANALYSIS

ROLE OF THE PARSER

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
To evaluate the ____ expression, a stack is used.
A
postfix
B
prefix
C
both
D
polish
Explanation: 

Detailed explanation-1: -Stack data structure is suitable for evaluating postfix expression. Stack : Stack is a linear data structure in which elements are inserted and deleted from one end only i.e. top of the stack. It follows a order to insert the elements into stack which is known as LIFO (Last in first out).

Detailed explanation-2: -A postfix expression can be evaluated using the Stack data structure.

There is 1 question to complete.