Question: PART B PLEASE. 1. (a) Consider the following grammar: E + E+TE-TT T + T F T/FF F (E) | id Why is this grammar

PART B PLEASE.

PART B PLEASE. 1. (a) Consider the following grammar: E + E+TE-TT

1. (a) Consider the following grammar: E + E+TE-TT T + T F T/FF F (E) | id Why is this grammar not LL? Give a rightmost derivation and parse tree for the following expression: 7-8* (3 + 2) / 4 + 11 Note that all the numbers are ids, as in class, and I'm asking for BOTH the derivation and the parse tree (which are not always identical). (b) Now consider an equivalent LL grammar: E T T' F + TE + +TE' -TE' + FT' *FT' /FT' E + (E) id Give a leftmost derivation and parse tree for the same expression: 7-8 * (3 + 2) / 4 + 11 Again, note that all the numbers are ids, as in class, and I'm asking for BOTH the derivation and the parse tree (which are not always identical)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!