Pham Quỳnh
New member
Consider the following grammar.
Consider the following LR (0) items corresponding to the grammar above.
Given the items above, which two of them will appear in the same set in the canonical sets-of-items for the grammar?
A. (ii)
B. (i) and (iii)
C. (iii)
D. None of the mentioned
Code:
S -> S * E
S -> E
E -> F + E
E -> F
F -> id
Code:
(i) S -> S * .E
(ii) E -> F. + E
(iii) E “F + .E
A. (ii)
B. (i) and (iii)
C. (iii)
D. None of the mentioned