Menu

Regular and context free languages Questions

MCQ
11.
Consider the following languages. 
gatecs2013.12
Which one of the following statements is FALSE?
forum Discussion
MCQ
12.
Which of the following pairs have DIFFERENT expressive power?
forum Discussion
MCQ
13.
 Consider the language L1,L2,L3 as given below. L1={0^{p}1^{q} | p,q \in N} L2={0^{p}1^{q} | p,q \in N and p=q} L3={0^{p}1^{q}0^{r} | p,q,r \in N and p=q=r} Which of the following statements is NOT TRUE?
forum Discussion
MCQ
14.
Let P be a regular language and Q be context-free language such that Q 	\subseteq P. (For example, let P be the language represented by the regular expression p*q* and Q be {pnqn|n \in N}). Then which of the following is ALWAYS regular?
forum Discussion
MCQ
15.
Consider the languages L1 = {0i1j | i != j}. L2 = {0i1j | i = j}. L3 = {0i1j | i = 2j+1}. L4 = {0i1j | i != 2j}.
forum Discussion
MCQ
16.
S -> aSa|bSb|a|b; The language generated by the above grammar over the alphabet {a,b} is the set of
forum Discussion
MCQ
17.
Let L = L1?L2, where L1 and L2 are languages as defined below:

L1 = {a^{m}b^{m}ca^{n}b^{n} | m, n >= 0 }
L2 = {a^{i}b^{j}c^{k} | i, j, k >= 0 }
Then L is
forum Discussion
MCQ
18.
The language L= {0i21i | i?0 } over the alphabet {0,1, 2} is:
forum Discussion
MCQ
19.
Consider the CFG with {S,A,B) as the non-terminal alphabet, {a,b) as the terminal alphabet, S as the start symbol and the following set of production rules

S --> aB        S --> bA
B --> b         A --> a
B --> bS        A --> aS
B --> aBB       A --> bAA
Which of the following strings is generated by the grammar?
forum Discussion
MCQ
20.
For the correct answer strings to above question, how many derivation trees are there?
forum Discussion