spunkyshooter / DFA

C++ programs for deterministic finite automata.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

DFA

C++ programs for some deterministic finite automata. It shows the transitions of the states and the result whether it is accepted or not.

Questions:

  1. Design a DFA to accept all the strings over alphabet {0,1} which are divisible by 3
  2. Design a DFA to accept all the strings over alphabet {a,b} , having "b" at the starting and "aba" at the end
  3. Design a DFA to accept all the strings over alphabet {a,b} ,having "abba" at the end
  4. Design a DFA to accept all the strings over alphabet {a,b} ,having even numner of a and odd number of b
  5. Design a DFA for accepting L = { w : Na(w) mod 3 > Nb(w) mod 3}
  6. Design a DFA for accepting L = { w : (Na(w) - Nb(w) )mod 3 > 0 }
  7. Design a DFA for accepting L = {ab^(n)a^(m) : n >= 2 , m >= 3}
  8. Design a DFA for accepting L = {ab^(5)a^(2) : w belongs to {a,b}^*}
  9. Design a DFA for accepting L = {w1abw2 : w1 belongs to {a,b}^* , w2 belongs to {a,b}^*}
  10. Design a DFA for accepting L = { w : (Na(w) + 2*Nb(w) )mod 3 < 0 }

About

C++ programs for deterministic finite automata.


Languages

Language:C++ 100.0%