Designing DFA module 2,3

133 Views Asked by At

I've question given by our professor:

= { ∈ {, }∗|#() ≡ 2,3 ( 5) ∧ #() = 0}

What I understand from this is that the number of a's divided by 5 with a remainder of 2 or 3 (7 times, 8 times,12,13....) and no b's at all.

I don't know how many states should be here and how even start it

1

There are 1 best solutions below

0
On BEST ANSWER

Hint:

  • Can you design a DFA to check whether the number of $a$'s in the string is $2, 3 \pmod{5}$?
  • Can you design a DFA to check whether the number of $b$'s is a multiple of $5$?

If you can do both, can you construct a product machine from these two DFAs?