CS712/CS812
Homework 1
Spring 2003
Due Date: April 21


ss    -> x y z
x     ->
x     -> A x B
y     -> 
y     -> C
z     -> D x

Given the above grammar:

  1. Compute the First sets for the nonterminals of the grammar.

  2. Compute the Follow sets for the nonterminals of the grammar.

  3. Compute the LL(1) Predict Sets for this grammar.

  4. Explain why the Predict Sets demonstrate that the grammar is LL(1).

Please turn-in your homework in class on Monday April 21. If you cannot be in class that day, please make arrangements to give me your paper in advance. No late papers will be accepted.

You are expected to do your own work on this assignment.


Last modified on April 16, 2003.

Comments and questions should be directed to hatcher@unh.edu