GateAI
Lexical Analysis, Parsing and SDT

GATE CSE 2018 · Q8

MCQ1 markEasy

Time

Which one of the following statements is FALSE?

Select one answerSingle correct

Pick an option to check

Solution

Step-by-step verified solution

Official answer: B) Type checking is done before parsing.

Lexical Analysis, Parsing and SDT

Let us evaluate the statements:

  • Option A: Context-free grammars (CFGs) are more expressive than regular grammars, so a CFG can be used to describe regular languages (tokens/lexical rules) as well as syntactic structures (syntax rules). This statement is true.

  • Option B: In the standard compiler pipeline, Type checking is performed during the Semantic Analysis phase, which occurs after the syntax analysis (parsing) phase, using the parse tree / abstract syntax tree constructed by the parser. Hence, type checking is done *after* parsing, making this statement FALSE.

  • Option C: High-level language code can be translated into various intermediate representations (IR) such as abstract syntax trees, DAGs, quadruples, triples, or 3-address code. This statement is true.

  • Option D: In runtime environments, arguments to a function are typically pushed onto the call stack (program stack) in the activation record. This statement is true.

Therefore, statement B is the false statement.

Try the question first, then check your work.

Think the official key or this write-up is wrong?

Report error or challenge

Examiner trap

The misconception this question tests

This Lexical Analysis, Parsing and SDT previous year question is Q8 of the GATE CSE 2018 paper. Find more GATE CSE PYQs on Lexical Analysis, Parsing and SDT in Compiler Design, or browse all GATE CSE PYQs.

Free diagnostic

Where do you stand for GATE?

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.

One GATE CSE PYQ every morning

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 in GATE CSE

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 it is the only one in GATE CSE 2018.

How GATE tests Lexical Analysis, Parsing and SDT

More from GATE CSE 2018

Share this solution

A plain-text card for WhatsApp or Telegram study groups.

GateAI solution cardGATE CSE 2018 · Q8 · MCQ

Which one of the following statements is FALSE?

Topic-wise GATE CS PYQs with verified steps

Independent practice explanation verified by the GateAI team. GATE is conducted by the IITs; question text follows the official paper.