The GATE Grind

GATE 2011 CS (CS1) – Question 11

Compiler Design · Lexical Analysis · 1 mark · Multiple choice

A compiler recognizes language keywords during

  1. Parsing
  2. Code generation
  3. Lexical analysis
  4. Dataflow analysis

Practise this question in The GATE Grind →

Show answer and explanation

Correct answer: (C) Lexical analysis

Explanation

The lexical analyzer groups characters into tokens and classifies reserved words as keyword tokens, often using a symbol-table lookup after identifier recognition. Parsing then consumes these tokens. Thus lexical analysis, C.

More Lexical Analysis questions

All Lexical Analysis questions →