Match the following according to input (from the left column) to the compiler phase (in the right column) that processes it:
List-I
(P) Syntax tree
(Q) Character stream
(R) Intermediate representation
(S) Token stream
List-II
(i) Code generator
(ii) Syntax analyzer
(iii) Semantic analyzer
(iv) Lexical analyzer
- AP (ii), Q (iii), R (iv), S (i)
- BP (ii), Q (i), R (iii), S (iv)
- CP (iii), Q (iv), R (i), S (ii)
- DP (i), Q (iv), R (ii), S (iii)

