force parsing. It is a form of top-down parsing, which we can view as the
construction of a derivation tree from the root down.
Example 5.7
Consider the grammar
and the string w = aabb. Round one gives us
The last two of these can be removed from further consideration for obvious
reasons. Round two then yields sentential forms
which are obtained by replacing the leftmost S in sentential form 1 with all
applicable substitutes. Similarly, from sentential form 2 we get the additional
sentential forms
Again, several of these can be removed from contention. On the next round, we
find the actual target string from the sequence
Therefore, aabb is in the language generated by the grammar under
Précédent

- 176/532

Suivant