Which of the following statements about parser is/are CORRECT? I. Canonical LR is more powerful than SLR. II. SLR is more powerful than LALR. III. SLR is more powerful than Canonical LR.
Topic-wise GATE CS PYQs with verified steps
GATE CSE 2017 Set 2 · Q6
Time
Select one answerSingle correct
Solution
Official answer: A) I only
Lexical Analysis, Parsing and SDTThe relative expressive power (the set of grammars that can be parsed without conflicts) of LR parsers is:
Statement I is TRUE: Canonical LR (CLR) is strictly more powerful than SLR.
Statement II is FALSE: LALR is strictly more powerful than SLR (SLR is less powerful than LALR).
Statement III is FALSE: SLR is less powerful than Canonical LR.
Thus, only statement I is correct, matching option (A).
Try the question first, then check your work.
Examiner trap
Recall the hierarchy of bottom-up parsers in terms of parsing power: .
This Lexical Analysis, Parsing and SDT previous year question is Q6 of the GATE CSE 2017 Set 2 paper. Find more GATE CSE PYQs on Lexical Analysis, Parsing and SDT in Compiler Design, or browse all GATE CSE PYQs.
Free diagnostic
Take the 20-minute diagnostic: the 3 topics that cost you the most marks, and a rank range. Or sit 5 related Lexical Analysis, Parsing and SDT PYQs now with no account.
An official question by email at 7 AM IST, with a link to its verified solution. Unsubscribe in one click.
Lexical Analysis, Parsing and SDT has 14 GATE CSE PYQs across 12 papers from 2011 to 2025. 9 of them are 1-mark MCQs like this one, and GATE CSE 2017 Set 2 has 2.
How GATE tests Lexical Analysis, Parsing and SDTIndependent practice explanation verified by the GateAI team. GATE is conducted by the IITs; question text follows the official paper.