DFA for this language

Σ = {a, b, c, d} L = {x ∈ Σ * | x does not start or end with "bab"}

Examples to be taken:

  • ababa
  • ababc
  • bbabb
  • bbaba
  • ab
  • ba
  • ahhh
  • ɛ

Examples to reject:

  • women
  • Women
  • V.A.V.S.
  • cbab
  • ABAB

I tried several times and got this so far: my try

The main problem with my dfa is that it accepts "bbab"

Thank.

+3


source to share


1 answer


That's what i can fast come up with.



Slightly less gritty drawing

+1


source







All Articles