GateAI
Regular Expressions and Finite Automata

GATE CSE 2015 Set 3 · Q18

MCQ1 markMedium

Time

Let L 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{\text{L}} (complement of L)?

Select one answerSingle correct

Pick an option to check

Solution

Step-by-step verified solution

Official answer: B) 5

Regular Expressions and Finite Automata

The language L=Σ∗0011Σ∗L = \Sigma^* 0011 \Sigma^* consists of all binary strings that contain the substring 00110011.

The minimal complete DFA for language LL requires 55 states corresponding to the length of the longest prefix of 00110011 matched so far:

  1. State q0q_0: ϵ\epsilon matched (start state)

  2. State q1q_1: 00 matched

  3. State q2q_2: 0000 matched

  4. State q3q_3: 001001 matched

  5. State q4q_4: 00110011 matched (accepting/dead state for LL)

To construct the minimal DFA for the complement language L‾\overline{L}:

  • We keep the exact same state set and transition function of the minimal complete DFA for LL, and invert the final states (non-accepting states become accepting, and accepting states become non-accepting).

  • Since complementing the accepting states in a minimal complete DFA results in a minimal DFA for the complement language, the number of states remains unchanged.

Number of states in minimal DFA for L‾=5\text{Number of states in minimal DFA for } \overline{L} = 5

Hence, the correct option is (B).

Try the question first, then check your work.

Think the official key or this write-up is wrong?

Report error or challenge

Examiner trap

The misconception this question tests

This Regular Expressions and Finite Automata previous year question is Q18 of the GATE CSE 2015 Set 3 paper. Find more GATE CSE PYQs on Regular Expressions and Finite Automata in Theory of Computation, or browse all GATE CSE PYQs.

Free diagnostic

Where do you stand for GATE?

Take the 20-minute diagnostic: the 3 topics that cost you the most marks, and a rank range. Or sit 5 related Regular Expressions and Finite Automata PYQs now with no account.

One GATE CSE PYQ every morning

An official question by email at 7 AM IST, with a link to its verified solution. Unsubscribe in one click.

Regular Expressions and Finite Automata in GATE CSE

Regular Expressions and Finite Automata has 41 GATE CSE PYQs across 24 papers from 2011 to 2026. 14 of them are 1-mark MCQs like this one, and it is the only one in GATE CSE 2015 Set 3.

How GATE tests Regular Expressions and Finite Automata

More from GATE CSE 2015 Set 3

Share this solution

A plain-text card for WhatsApp or Telegram study groups.

GateAI solution cardGATE CSE 2015 Set 3 · Q18 · MCQ

Let L be the language represented by the regular expression * 0011 * where = {0, 1}. What is the minimum number of states in a DFA that recognizes L (complement of L)?

Topic-wise GATE CS PYQs with verified steps

Independent practice explanation verified by the GateAI team. GATE is conducted by the IITs; question text follows the official paper.