Skip to main content

Differentiate DFA and NFA

Short answer

In a DFA, each state has exactly one transition per input symbol. In an NFA, a state may have zero, one, or multiple transitions, including ε-moves. A DFA can need up to 2^n states to simulate an n-state NFA, but both accept the same regular languages.

Differentiate between Deterministic Finite State Automata and Non-Deterministic Finite State Automata.

PointDFANFA
Next stateExactly one for each (state, symbol)Zero, one or many for each (state, symbol)
Transition functionδ : Q × Σ → Qδ : Q × Σ → 2^Q (set of states)
ε-movesNot allowedAllowed in the ε-NFA variant
Dead stateNeeded to make δ totalMissing transitions simply mean rejection
ExecutionFollows a single pathMany paths possible; accepts if any path ends in a final state
SizeThe DFA equivalent to an n-state NFA may need up to 2ⁿ statesUsually fewer states, easier to design
PowerAccepts regular languagesAccepts the same regular languages

✓ Answer checked by Claude Opus 5.5 (high effort)

All Discrete Structure chapter 2 questions →