StreakPeaked· Practice

ExamsGATETechnical

Let M be the 5-state NFA with ε-transitions shown in the diagram below. Which one of the following regular expressions represents the language accepted by M ?

  1. (00)* + 1(11)*
  2. 0* + (1 + 0(00)*)(11)*
  3. (00)* + (1 + (00)*)(11)*
  4. 0* + 1(11)* + 0(11)*

Correct answer: 0* + (1 + 0(00)*)(11)*

Solution

The correct option accurately captures the language accepted by the NFA by allowing for any number of leading zeros, followed by either a single '1' or a sequence starting with '0' followed by any number of '00's, and concluding with any number of '11's. This structure reflects the transitions and states of the NFA, ensuring all valid strings are included.

Related GATE Technical questions

⚔️ Practice GATE Technical free + battle 1v1 →