{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Lecture 10 Notes

# A a int a 4 3

This preview shows page 1. Sign up to view the full content.

This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: is a list of integers. We can write this as another instance of the second rule for List-of-Int .   List-of-Int List-of-Int ¡ ¢  ¡ ¢   A     ¢A Int ¢    ¢       ¡ £      ¡ £ A ¤ ¥ is a list of integers, because of property 2, since is a integer and is a list of integers. Once more we can write this as an instance of the second rule for List-of-Int . ¢   ¢    ¡ ¢    ¡ ¢ A ¡ ¢    A Int    A    ¤ ¦      4.  ¡ ¢     3. ¢ Int List-of-Int List-of-Int ¤ ¥ ¤ ¦ ¢  5. Nothing is a list of integers unless it is built in this fashion. 8 1.4 Deﬁning Sets Using Grammars Normally use grammars to deﬁne sets of strings, but can use them to deﬁne sets as well.  List-of-Int Int    List-of-Int :: List-of-Int :: two rules, corresponding to the two properties in Deﬁnition 5 above. In this deﬁnition we have Nonterminal Symbols. These are the names of the sets being deﬁned. In this case there is only one such set, but in general, there might be several sets being deﬁned. These sets are...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online