GATE / CS ARCHIVE

GATE CSE 2016 SET 2 / QUESTION 16

GATE CSE 2016 Set 2 Q16

Theory of Computation · Finite Automata · Full GATE CSE 2016 Set 2 paper

GATE 2016 Set 2, Q16 1 mark · NAT
Report issue

Finite Automata

Question 16, GATE 2016: How many states does a minimum DFA need for (0+1)*(0+1)(0+1)*, where + denotes union?
Tap to enlarge
Answer & solution

Official answer: 2.0 : 2.0

Our answer: 2

Step through it (2 parts)

The expression Σ*ΣΣ* is exactly the nonempty binary strings. Use a nonaccepting start state and one accepting state reached by either symbol, with both loops on the latter. The empty string differs from every nonempty word, so at least two states are necessary.

The mandatory middle (0+1) contributes at least one symbol, while the starred parts may be empty. The transition table is start:0→accept,1→accept; accept:0→accept,1→accept. The empty suffix distinguishes start from accept because only one is accepting, establishing minimality rather than merely constructing a two-state automaton.

Original paper, page 29 · Answer key