Questions: Deterministic Finite Automata

5 questions to test your understanding

Score: 0 / 5
Question 1 Multiple Choice

What is the minimum number of states needed for a DFA that recognizes binary strings where the number of 1s is divisible by 3?

A3 states — one for each remainder (0, 1, 2) when the count of 1s is divided by 3
B4 states — three for remainders plus a dedicated start state
CInfinitely many — the DFA must count arbitrary numbers of 1s, requiring unbounded memory
D2 states — one accepting state (divisible by 3) and one rejecting state (not divisible)
Question 2 Multiple Choice

Which of the following languages can a DFA recognize?

AAll binary strings containing an even number of 1s
BAll strings of the form aⁿbⁿ for n ≥ 1 (equal numbers of a's followed by equal numbers of b's)
CAll palindromes over the alphabet {a, b}
DAll strings where the total number of a's equals the total number of b's
Question 3 True / False

In a DFA, the transition function need not be defined for most (state, symbol) pair — when no transition is defined for a given symbol, the DFA implicitly rejects the input.

TTrue
FFalse
Question 4 True / False

The minimum number of states in a DFA for a given language is related to the number of distinguishable histories of input prefixes — strings that will cause the DFA to behave differently going forward.

TTrue
FFalse
Question 5 Short Answer

Why can a DFA recognize 'binary strings with an even number of 1s' but cannot recognize 'strings of the form aⁿbⁿ'? What property of DFAs explains the boundary?

Think about your answer, then reveal below.