GATE CSE
Compiler Design
Lexical Analysis
Previous Years Questions

## Marks 1

In a compiler, keywords of a language are recognized during
Which data structure in a compiler is used for managing information about variables and their attributes?
Match all items in Group 1 with correct options from those given in Group 2. Group 1 P. Regular expression Q. Pushdown automata R. Dataflow analysis S...
The number of tokens in the following C statement is: printf("i = %d, &i = %x",i, &i);
Type checking is normally done during
In some programming languages, an identifier is permitted to be a letter following by any number of letters or digits. If L and D denote the sets of l...
Which of the following strings can definitely be said to be tokens without looking at the next input character while compiling a Pascal program? I. be...
Match the following: List - I (a) Lexical Analysis (b) Code Optimization (c) Code Generation (d) Abelian Group List - II (p) DAG's (q) Synta...
In a compiler the module that checks every character of the source text is called:

## Marks 2

Consider the following C code segment: a = b + c; e = a + 1; d = b + c; f = d + 1; g = e + f; In a compiler, this code segment is...
Which one of the following statements is FALSE?
A lexical analyzer uses the following patterns to recognize three tokens $${T_1},{T_2},$$ and $${T_3}$$ over the alphabet $$\left\{ {a,b,c} \right\}.... Which one of the following grammars is free from$$leftrecursion?
Which of the following are true? I. A programming language which does not permit global variables of any kind and has no nesting of procedures/functi...
The number of tokens in the Fortran statement DO 10 I = 1.25 is
EXAM MAP
Joint Entrance Examination