Regular Languages questions — page 3 of 3

Q17

GATE CS 2016 CS-2Regular LanguagesMCQ1 mark−1/3 if wrong
Language L1L_1 is defined by the grammar: S1→aS1b∣εS_1 \to aS_1b \mid \varepsilon
Language L2L_2 is defined by the grammar: S2→abS2∣εS_2 \to abS_2 \mid \varepsilon

Consider the following statements:
PP: L1L_1 is regular
QQ: L2L_2 is regular

Which one of the following is TRUE?
Show answer without attempting

Answer: C

Q42

GATE CS 2016 CS-2Regular LanguagesMCQ2 marks−2/3 if wrong
Consider the following two statements:

I. If all states of an NFA are accepting states then the language accepted by the NFA is Σ∗\Sigma^*.
II. There exists a regular language AA such that for all languages BB, A∩BA \cap B is regular.

Which one of the following is CORRECT?
Show answer without attempting

Answer: B

Q32

GATE CS 2015 CS-3Regular LanguagesMCQ1 mark−1/3 if wrong
Let LL be the language represented by the regular expression Σ∗0011Σ∗\Sigma^* 0011 \Sigma^* where Σ={0,1}\Sigma = \{0, 1\}. What is the minimum number of states in a DFA that recognizes L‾\overline{L} (complement of LL)?
Show answer without attempting

Answer: B

Q49

GATE CS 2015 CS-1Regular LanguagesNAT2 marks
Consider the DFAs M and N given above. The number of states in a minimal DFA that accepts the language L(M)∩L(N)L(M) \cap L(N) is ________.
Question figure
Show answer without attempting

Answer: 1

Q45

GATE CS 2015 CS-2Regular LanguagesNAT2 marks
The number of states in the minimal deterministic finite automaton corresponding to the regular expression (0+1)∗(10)(0 + 1)^*(10) is ___________.
Show answer without attempting

Answer: 3

Q46

GATE CS 2015 CS-2Regular LanguagesMCQ2 marks−2/3 if wrong
Which of the following languages is/are regular?

L1L_1: {wxwR∣w,x∈{a,b}∗ and ∣w∣,∣x∣>0}\{wxw^R \mid w, x \in \{a, b\}^* \text{ and } |w|, |x| > 0\}, wRw^R is the reverse of string ww
L2L_2: {anbm∣m≠n and m,n≥0}\{a^n b^m \mid m \neq n \text{ and } m, n \geq 0\}
L3L_3: {apbqcr∣p,q,r≥0}\{a^p b^q c^r \mid p, q, r \geq 0\}
Show answer without attempting

Answer: A

Q60

GATE CS 2015 CS-2Regular LanguagesMCQ2 marks−2/3 if wrong
Consider the alphabet Σ={0,1}\Sigma = \{0, 1\}, the null/empty string λ\lambda and the sets of strings X0X_0, X1X_1, and X2X_2 generated by the corresponding non-terminals of a regular grammar. X0X_0, X1X_1, and X2X_2 are related as follows.

X0=1X1X_0 = 1 X_1
X1=0X1+1X2X_1 = 0 X_1 + 1 X_2
X2=0X1+{λ}X_2 = 0 X_1 + \{\lambda\}

Which one of the following choices precisely represents the strings in X0X_0?
Show answer without attempting

Answer: C

Q15

GATE CS 2014 CS-2Regular LanguagesMCQ1 mark−1/3 if wrong
If L1={an∣n≥0}L_1 = \{a^n \mid n \geq 0\} and L2={bn∣n≥0}L_2 = \{b^n \mid n \geq 0\}, consider

(I) L1⋅L2L_1 \cdot L_2 is a regular language
(II) L1⋅L2={anbn∣n≥0}L_1 \cdot L_2 = \{a^n b^n \mid n \geq 0\}

Which one of the following is CORRECT?
Show answer without attempting

Answer: A

Q36

GATE CS 2014 CS-2Regular LanguagesMCQ2 marks−2/3 if wrong
Let L1={w∈{0,1}∗∣w has at least as many occurrences of (110)’s as (011)’s}L_1 = \{w \in \{0,1\}^* \mid w \text{ has at least as many occurrences of (110)'s as (011)'s}\}. Let L2={w∈{0,1}∗∣w has at least as many occurrences of (000)’s as (111)’s}L_2 = \{w \in \{0,1\}^* \mid w \text{ has at least as many occurrences of (000)'s as (111)'s}\}. Which one of the following is TRUE?
Show answer without attempting

Answer: A

Q15

GATE CS 2014 CS-3Regular LanguagesNAT1 mark
The length of the shortest string NOT in the language (over Σ={a,b}\Sigma = \{a, b\}) of the following regular expression is ______________.

a∗b∗(ba)∗a∗a^*b^*(ba)^*a^*
Show answer without attempting

Answer: 3

Q15

GATE CS 2014 CS-1Regular LanguagesMCQ1 mark−1/3 if wrong
Which one of the following is TRUE?
Show answer without attempting

Answer: C

Q16

GATE CS 2014 CS-1Regular LanguagesMCQ1 mark−1/3 if wrong
Consider the finite automaton in the following figure.

What is the set of reachable states for the input string 0011?
Question figure
Show answer without attempting

Answer: A

Q36

GATE CS 2014 CS-1Regular LanguagesMCQ2 marks−2/3 if wrong
Which of the regular expressions given below represent the following DFA?

I) 0∗1(1+00∗1)∗0^*1(1+00^*1)^*
II) 0∗1∗1+11∗0∗10^*1^*1+11^*0^*1
III) (0+1)∗1(0+1)^*1
Question figure
Show answer without attempting

Answer: B

Q8

GATE CS 2013 CSRegular LanguagesMCQ1 mark−1/3 if wrong
Consider the languages L1=ΦL_1 = \Phi and L2={a}L_2 = \{a\}. Which one of the following represents L1L2∗∪L1∗L_1 L_2^* \cup L_1^*?
Show answer without attempting

Answer: A

Q33

GATE CS 2013 CSRegular LanguagesMCQ2 marks−2/3 if wrong
Consider the DFA A given below.

Which of the following are FALSE?

1. Complement of L(A)L(A) is context-free.
2. L(A)=L((11∗0+0)(0+1)∗0∗1∗)L(A) = L((11^*0+0)(0 + 1)^*0^*1^*)
3. For the language accepted by A, A is the minimal DFA.
4. A accepts all strings over {0,1}\{0, 1\} of length at least 2.
Question figure
Show answer without attempting

Answer: D

Q12

GATE CS 2012 CSRegular LanguagesMCQ1 mark−1/3 if wrong
What is the complement of the language accepted by the NFA shown below?
Assume Σ={a}\Sigma = \{a\} and ϵ\epsilon is the empty string.

(In the figure, the edge label printed as η denotes ϵ\epsilon.)
Question figure
Show answer without attempting

Answer: B

Q25

GATE CS 2012 CSRegular LanguagesMCQ1 mark−1/3 if wrong
Given the language L={ab,aa,baa}L = \{ab, aa, baa\}, which of the following strings are in L∗L^*?

1) abaabaaabaa
2) aaaabaaaa
3) baaaaabaaaab
4) baaaaabaa
Show answer without attempting

Answer: C

Q46

GATE CS 2012 CSRegular LanguagesMCQ2 marks−2/3 if wrong
Consider the set of strings on {0,1}\{0,1\} in which, every substring of 3 symbols has at most two zeros. For example, 001110 and 011001 are in the language, but 100010 is not. All strings of length less than 3 are also in the language. A partially completed DFA that accepts this language is shown below.

(In the figure, the start state printed as η is the state for the empty string ϵ\epsilon.)

The missing arcs in the DFA are
Question figure
Show answer without attempting

Answer: D

0/180 correct0 marks

Related topics in Theory of Computation