Menu

Regular Expressions Questions

MCQ
21.
Which grammar is not regular
forum Discussion
MCQ
22.
If is a language, and is a symbol, then, the quotient of and, is the set of strings such that is in: is in. Suppose is regular, which of the following statements is true?
forum Discussion
MCQ
23.
Here is a context-free grammar G: S ? AB A ? 0A1 | 2 B ? 1B | 3A which of the following strings are in L (G)?
forum Discussion
MCQ
24.
The grammar G: S ? SS | a | b is ambiguous. Check all and only the strings that have exactly two leftmost derivations in G
forum Discussion
MCQ
25.
For the following grammar: S ? A | B | 2 A ? C0 | D B ? C1 | E C ? D | E | 3 D ? E0 | S E ? D1 | S Identify all the unit pairs
forum Discussion
MCQ
26.
The classes of languages P and NP are closed under certain operations, and not closed under others. Decide whether P and NP are closed under each of the following operations.
1. Union

2. Intersection

3. Intersection with a regular language

4. Kleene closure (star)

5. Homomorphism
forum Discussion
MCQ
27.
Consider the languages L1 = and L2 = {a}. Which one of the following represents L1 L2* U L1*
forum Discussion
MCQ
28.
Given the language L = {ab, aa, baa}, which of the following strings are in L*?
1) abaabaaabaa

2) aaaabaaaa

3) baaaaabaaaab

4) baaaaabaa
forum Discussion
MCQ
29.
Given the language L = {ab, aa, baa}, which of the following strings are in L*?
1) abaabaaabaa

2) aaaabaaaa

3) baaaaabaaaab

4) baaaaabaa
forum Discussion
MCQ
30.
Which of the following are regular sets?
I. { a^n b^2m | n>=0, m>=0}

II. {a^n b^m |n=2m}

III. {a^n b^m | n!= m}

IV {xcy |x,y
forum Discussion