CS480 Review

1) The grammar for your top-down parser fits into what class of grammars?

 

2) What characteristics of the grammar are necessary for your top-down parser to properly work?

 

 

 

3) The grammar for your bottom-up parser fits into what class of grammars?

 

4) What characteristics of the grammar are necessary for your bottom-up parser to properly work.

 

 

 

5) Construct an operator-precedence grammar that has id, +, -, *, and / as terminal symbols such that *, and / have highest precedence and are left associative and + and – have lowest precedence and are left-associative.

 

 

 

6) Construct the operator precedence table for the grammar in 5).

 

 

 

 

7) What in the operator precedence table reflects operator associativity if anything?