Comprehension

A machine is represented by states Q, input alphabet Σ, transition function δ. Initial state qo and final state F. The machine accepts all the strings over Σ = {a,b}, which starts and ended with any combination of all alphabet and abb works/lies in all the strings to be accepted 

For the above specified passage, which of the following is DFA for the language represented/accepeted by machine?

  1. qImage67a74bb8b8840bd62b8ff387
  2. qImage67a74bb9b8840bd62b8ff388
  3. qImage67a74bbab8840bd62b8ff389
  4. qImage67a74bbab8840bd62b8ff38a

Answer (Detailed Solution Below)

Option 3 : qImage67a74bbab8840bd62b8ff389

Detailed Solution

Download Solution PDF

The correct answer is : Option 3

Key Points

Option 1: This DFA starts with state 1 looping on a and b. Then from 1 --a--> 2, 2 --b--> 3, and 3 --b--> 4. After reaching state 4, it loops on a and b and accepts. Looks promising, but lacks rejection for incorrect sequences like “aba”. It accepts too many patterns and has no trap state to reject wrong combinations. Incorrect.

Option 2: This DFA takes a → b → a → b → final. This structure doesn’t track “abb” correctly; it adds unnecessary transitions and doesn’t form the required substring properly. Incorrect.

Option 3: This DFA clearly implements the pattern detection:

  • q1 --a--> q2
  • q2 --b--> q3
  • q3 --b--> q4 (final)
  • q4 is the accepting state, loops on all inputs (a, b)
  • Other transitions (like wrong 'a' or 'b') push to dead states
This structure correctly captures the presence of “abb” as a substring.
Correct Answer ✔

 

Get Free Access Now
Hot Links: teen patti 3a teen patti real cash withdrawal teen patti real cash