Question: Consider the languages A = {a^m b^n c^n | m, n ? 0} and B = {a^n b^n c^m | m, n ? 0}. (a)

Consider the languages A = {a^m b^n c^n | m, n ? 0} and B = {a^n b^n c^m | m, n ? 0}.

(a) Give a context-free grammar for each of A and B. Then, use A and B to show that the class of context free languages is not closed under intersection.

(b) Use (a) and DeMorgans Law (Textbook Theorem 0.20) to show that he class of context-free languages is not closed under complementation.

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!