Question

5. What is different about the following gram Is it more or less expressive than the grammar in problem 3? Is it ambiguous? <zip> szap a <zap> I a <Zap> b l a l <zip
0 0
Add a comment Improve this question Transcribed image text
Answer #1

String "aaa" can be generated more than one parse tree.

zip->zap a zap, here zap can be substituted by a in both places to generate aaa.

Another way, one of the zap can be substituted by zip then zip can be substituted by a. Another zap can be substituted by a.

There are other ways to generate aaa.

Hence the grammar is ambiguous.

Add a comment
Know the answer?
Add Answer to:
What is different about the following grammar? Is it more or less expressive than the grammar...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT