Question
Official answer and solution
- Official answer
- D
- From
- Official GATE 2013 answer key
Solution
Trace the language accepted by the DFA, check state equivalence for minimization, and evaluate the truth value of each statement.
Let us inspect the given DFA :
- State 0 is the start state.
- State 1 is an intermediate non-accepting state.
- State 2 is the accepting state.
Transitions:
- From state 0: on 0 state 2; on 1 state 1.
- From state 1: on 0 state 2; on 1 state 1 (self-loop).
- From state 2: on 0 state 2; on 1 state 2 (trap/accepting self-loop).
Notice that if any string contains at least one '0':
- If it starts with 0, it immediately reaches state 2 (accepting).
- If it starts with one or more 1s, it stays in state 1 until the first 0 appears, which moves it to state 2 (accepting).
- Once in state 2, all further symbols keep it in state 2.
Thus, is the set of all strings over containing at least one '0':
Now test each statement:
- Complement of is context-free: The complement of is the set of strings with no zeros, which is . Since is regular, it is also context-free. Thus, statement 1 is TRUE.
- : Notice . The expression simplifies to . Thus, , which matches exactly all strings containing at least one '0'. Thus, statement 2 is TRUE.
- For the language accepted by A, A is the minimal DFA:
Examine states 0 and 1:- and .
- and .
Both states transition to the exact same state for every input symbol, and neither is an accepting state. Therefore, states 0 and 1 are equivalent and can be merged into a single start state. The minimal DFA for has only 2 states. Hence, A is not minimal. Statement 3 is FALSE.
- A accepts all strings over of length at least 2:
Consider the string "11". Its length is 2, but on input "11", the automaton transitions . State 1 is not accepting, so "11" is rejected. Thus, statement 4 is FALSE.
Statements 3 and 4 are FALSE, which corresponds to option (D).
Final answer
D
The answer is the one in the official GATE answer key. The solution is this site's own explanation.
Source
- Paper
- GATE 2013 Computer Science and Information Technology (CS)
- Question
- 33 of 65, printed as CS Q.33
- Section
- Computer Science and Information Technology
Report an error in this question
GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.