Re: A question about a LL parser



grocery_stocker wrote:

The question comes from the following URL

http://en.wikipedia.org/wiki/LL_parser

They parse ( 1 + 1 ), using the following grammar rules.

1. S $B"*(B F
2. S $B"*(B ( S + F )
3. F $B"*(B 1

On the first '(' from the input stream and from the 'S' stack, they
apply rule 2. How do they know it's rule 2 and say not rule 1?

They look it up in the parsing table.

--
Reinier
.