Explanation : t is LL(1) and LR(1)
because in S → aSa
S → bS
S → c
no mult iple ent r ies for 1 iteration, so it is LL(1)
grammer mean by LR(1) that it is Left shift
Reduced grammer and so it is also LR(1).
Hence it is both LL(1) and LR(1)
Explanation : As per given question, a grammar with no epsilon and
unit -production (i.e., of type A → ε and A →
a).
So To Reduce input string of n tokens, first Reduce
n – 2 tokens using n – 2 reduce moves and then
Reduce last 2 tokens using production which has.
So total of n – 2 + 1 = n – 1 Reduce moves
Explanation : (1) false, as merging has been done because lookahead
were different.
(2) false, Shift-Reduce conflict never occur at the
time of merging.
(3) false, In the merged set, we can’t see any
Reduce-Reduce conflict (no reduction even
possible, so no chances of R-R conflict )
(4) false, because goto is carried on Non-Terminals
symbols, not on terminal symbols, and c is a
terminal symbol.