Back to the 2026 paper

Module 1: Introduction, Lexical Analysis

20262m

Which statement is true regarding DFA and NFA?
(i) NFA is strictly more powerful than DFA
(ii) DFA and NFA recognize the same class of languages
(iii) DFA is strictly more powerful than NFA
(iv) Every NFA requires more states than every equivalent DFA

Worked SolutionAI Assisted

Answer: (ii) DFA and NFA recognize the same class of languages

Explanation

Both DFAs and NFAs recognize exactly the regular languages.

  • Every DFA is already an NFA (a special case).
  • Every NFA can be converted to an equivalent DFA by the subset construction.

So neither is more powerful, which rules out (i) and (iii). An NFA is often smaller than the equivalent DFA: an NFA with nn states may need up to 2n2^n DFA states. That is a size difference only, and option (iv) is false because many NFAs need no more states than their DFAs (a DFA is itself an NFA).

(ii)\boxed{\text{(ii)}}

Similar questions

Budget AppAndroid App

Pocketly on Android

Log daily food, travel, and hostel expenses instantly. Set monthly spending limits and see where your money goes without complex spreadsheets.