A context free grammar is said to be a strong LL(k) grammar if for
every pair of production rules
and
the following condition holds.
The FIRST, FOLLOW, and SELECT algorithms can be generalized to
symbols for use with strong LL(k) grammars.
1.
2.
3.
4.
5.
6.
FIRST
FOLLOW
A
aa, ab, bb
$$
B
b,
aa
C
b,
bb
aa
ab
ba
bb
A
1
1
2
B
4
3
C
6
5
A grammar is said to be LL(k) grammar if each step in a derivation can be
determined from the already constructed parse tree and the k lookahead
symbols.
The following grammar is LL(2) but not strong LL(2).