0
9.8kviews
Let G be the grammar. Find the leftmost derivation, rightmost derivation and parse tree for the string 001222.

G: S =>0S|1A|2B|ε

A =>1A|2B| ε

B =>2B| ε

1 Answer
0
459views

Let G be the grammar. Find the leftmost derivation, rightmost derivation and parse tree for the string 001222.

G: S =>0S|1A|2B|ε

A =>1A|2B| ε

B =>2B| ε

If we solve the sum using the given grammar, we can produce the string using leftmost derivation alone, but not the rightmost derivation. …

Create a free account to keep reading this post.

and 4 others joined a min ago.

Please log in to add an answer.