GATE | GATE-CS-2017 (Set 2) | Question 12

Match the following according to input(from the left column) to the compiler phase(in the right column) that process it:

g2017_1
(A) P -> (ii), Q -> (iii), R -> (iv), S -> (i)
(B) P -> (ii), Q -> (i), R -> (iii), S -> (iv)
(C) P -> (iii), Q -> (iv), R -> (i), S -> (ii)
(D) P -> (i), Q -> (iv), R -> (ii), S -> (iii)


Answer: (C)

Explanation: P – iii Syntax tree is input to semantic analyser

Q – iv Character stream is input to lexical analyser.



R – i Intermediate code is input to code generator

S -ii  Token stream is input to syntax analyser.

Therefore option C

Quiz of this Question



My Personal Notes arrow_drop_up