Skip to content
Early access — you're among the first to try PYQLabs. Share feedback
Concept drill

parsing

GATE CSE & IT · Parsing · 2001-2025

30
PYQs
93%
keyed
0
elite explanations
15
years appeared

Study anchor

Hopcroft-Ullman / Dragon Book

Automata, languages, parsing, syntax-directed translation

Practice action

Start latest PYQ

PYQs in this concept

All concepts →
2025 Q12

Which ONE of the following statements is FALSE regarding the symbol table?

mediumanswer key
2025 Q40

Given a Context-Free Grammar G as follows: S→Aa | bAc | dc | bda A→d Which ONE of the following statements is TRUE?

mediumanswer key
2025 Q46

Which of the following statement(s) is/are TRUE while computing First and Follow during top down parsing by a compiler?

mediumanswer key
2025 Q51

Consider two grammars G₁ and G₂ with the production rules given below: G₁: S → if E then S | if E then S else S | a E → b G₂: S → if E then S | M M → if E then M else S | c E → b w...

mediumanswer key
2025 PYQ

Which of the following statement(s) is/are TRUE while computing First and Follow during top down parsing by a compiler?

easyanswer keybasic explanation
2025 PYQ

Consider two grammars $G_1$ and $G_2$ with the production rules given below: $G_1: S \rightarrow$ if $E$ then $S \mid$ if $E$ then $S$ else $S \mid a$ $$\mathrm{E} \rightarrow \mat...

mediumanswer keybasic explanation
2024 Q26

Which of the following is/are Bottom-Up Parser(s)?

mediumanswer key
2024 Q29

Which of the following statements is/are FALSE?

mediumanswer key
2024 Q38

Consider the following grammar G, with S as the start symbol. The grammar G has three incomplete productions denoted by (1), (2), and (3). S → daT | ____ (1) T → aS | bT | ____ (2)...

mediumanswer key
2024 Q65

Consider the following augmented grammar, which is to be parsed with a SLR parser. The set of terminals is {a,b,c,d,#,@} S' → S S → SS | Aa | bAc | Bc | bBa A → d# B → @ Let I₀ = C...

mediumanswer key
2024 PYQ

Which of the following is/are Bottom-Up Parser(s)?

easyanswer keybasic explanation
2024 PYQ

Consider the following syntax-directed definition (SDD). S → DHTU { S.val = D.val + H.val + T.val + U.val; } D → “M” D 1 { D.val = 5 + D 1 .val; } D → ε { D.val = –5; } H → “L” H 1...

mediumanswer keybasic explanation
2024 PYQ

Consider the following grammar $G$, with $S$ as the start symbol. The grammar $G$ has three incomplete productions denoted by (1), (2), and (3). $$S \rightarrow d a T \mid \underli...

mediumanswer keybasic explanation
2024 PYQ

Consider the following two sets: Set X P. Lexical Analyzer Q. Syntax Analyzer R. Intermediate Code Generator S. Code Optimizer Set Y 1. Abstract Syntax Tree 2. Token 3. Parse Tree...

easyanswer keybasic explanation
2022 PYQ

Which one of the following statements is TRUE?

mediumanswer keybasic explanation
2021 PYQ

Consider the following augmented grammar with {#, @, <, >, a, b, c} as the set of terminals. S' → S S → S # cS S → SS S → S @ S → < S > S → a S → b S → c Let I 0 = CLOSURE({S' → ∙...

mediumbasic explanation
2019 PYQ

Consider the augmented grammar given below : S' → S S → 〈L〉 | id L → L,S | S Let I 0 = CLOSURE ({[S' → ●S]}). The number of items in the set GOTO (I 0 , 〈 ) is: _____.

mediumbasic explanation
2017 Q32

Consider the following expression grammar G: E -> E - T | T T -> T + F | F F -> (E) | id Which of the following grammars is not left recursive, but is equivalent to G?

mediumanswer key
2016 PYQ

Which one of the following grammars is free from $$left$$ $$recursion$$?

mediumanswer key
2015 PYQ

Consider the following grammar $$G$$ $$\eqalign{ & \,\,\,\,\,\,\,S \to \,\,\,\,\,\,\,F|H \cr & \,\,\,\,\,\,F \to \,\,\,\,\,\,\,p|c \cr & \,\,\,\,\,\,H \to \,\,\,\,\,\,\,d|c \cr} $$...

easyanswer key
2010 PYQ

The grammar $$S \to aSa\,|\,\,bS\,|\,\,c$$ is

easyanswer key
2007 PYQ

Which one of the following is a top-down parser?

easyanswer key
2007 PYQ

Consider the grammar with non-terminals N = { S, C, S 1 }, terminals T = { a, b, i, t, e }, with S as the start symbol, and the following set of rules: $$\eqalign{ & S \to iCtS{S_1...

mediumanswer key
2006 PYQ

Consider the following grammar. $$\eqalign{ & S \to S*E \cr & S \to E \cr & E \to F + E \cr & E \to F \cr & F \to id \cr} $$ Consider the following LR(0) items corresponding to the...

mediumanswer key
2005 PYQ

Consider the grammar $$S \to \left( S \right)\,|\,a$$ Let the number of states in SLR(1), LR(1) and LALR(1) parsers for the grammar be n 1 , n 2 and n 3 respectively. The following...

mediumanswer key
2004 PYQ

Which of the following grammar rules violate the requirements of an operator grammar? P, Q, R are nonterminals, and r, s, t are terminals. $$\eqalign{ & 1.\,P \to QR \cr & 2.\,P \t...

easyanswer key
2004 PYQ

Which of the following grammar rules violate the requirements of an operator grammar ? $$P,$$ $$Q, R$$ are non-terminals and $$r, s, t$$ are terminals. $$$\eqalign{ & 1)\,\,\,P \to...

easyanswer key
2003 PYQ

Consider the grammar shown below. $$\eqalign{ & S \to CC \cr & C \to cC\,|\,d \cr} $$ This grammar is

easyanswer key
2003 PYQ

Which of the following suffices to convert an arbitrary CFG to an LL(1) grammar?

easyanswer key
2001 PYQ

Which of the following statements is false?

easyanswer key