next up previous
Next: Up: Previous:

Example

Here is a finite automaton accepting strings with an even number of ``a''s. $\Sigma$ = {a, b, c}.



\psfig{figure=figures/f24-2.ps}

$\delta$(s0, a) = s1
$\delta$(s0, b) = $\delta$(s0, c) = s0
$\delta$(s1, a) = s2
$\delta$(s1, b) = $\delta$(s1, c) = s1
$\delta$(s2, a) = s1
$\delta$(s2, b) = $\delta$(s2, c) = s2



\( A = \{ s_2 \}\)



Consider input string w. If w ends at state \(s \;\in\; A\), then the FA accepts w; otherwise, the FA rejects w.

Example: str = bccabaccaba

Accept


next up previous
Next: Up: Previous: