# COMPILER DESIGN: Dragon Book self doubt

1 vote
261 views
S→ A/a

A→ a

LL1 or not?
1
not LL1
1
Because S--> A and S--> a are the two productions of S for 'a' right?
1
yes..

this is not LL(1) because intersection is there,both are going to same cell infact this grammer is ambiguous.

Ambiguous grammer cannot parse by any parsers except operator precedence parser

If a grammar is ambiguous then it never be LL(1),LR(0),SLR,LALR,CLR.

Given grammar is ambiguous . So its not LL(1)
Given grammar is  ambiguous .even 2 parse tree generated for a string 'a'.
and if the grammar is ambiguous it can not be LL(1), LR(0),SLR(1), LALR(1) and CLR(1) also.
Not LL(1) ..not pair wise disjoint

## Related questions

1
164 views
S → aSbS /bSaS / ϵ S → aABb A→ c/ ϵ B → d/ ϵ Which of the following is LL1. Explain in details.
1 vote
In this why questions why the left recursion is not removed as it is necessary for $LL1$ Why they given the option without removing the left recursion $S->Aa|b$ $A->Ac|Sd|Null$