GATE | GATE 2017 MOCK II | Question 44

Which of the following is not a CFL?

A)L = {albmcn where l=m or l=n}
B)L = {albmcn where l=m and l=n}
C)L = {albmcn where l = m + n}

(A) Only A
(B) Only B
(C) B and C
(D) All


Answer: (B)

Explanation: Language in A is CFL because CFL can make one comparison which is either l and m must be equal or l and n must be equal. Similarly language in C is also CFL. But B is not because it has to make two comparisons. So language in B is CSL not CFL.

Quiz of this Question

My Personal Notes arrow_drop_up
Article Tags :

Be the First to upvote.


Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.