##########################################################################
# Logical Not Machine
# Comment line starts with '#'

# The states, delimited with ',' but no space, except h - the halt state
K = {qs,qs',q0,q1,q2}

# The set of alphabet, without #,L,R
E = {a,b}

# The start state
s = qs

# The transition function.  The first line must be "d =" and followed
#  by the lines of transitions.  Completely BLANK line and comment line
#  should be okay.  End the list of transition functions with a line
#  having '%' as the first character
d =

# Move to the first non-# symbol in the left
# Reach state q0 when it done!
qs-#/L->qs'
qs'-a/L->qs'
qs'-b/L->qs'
qs'-#/R->q0

q0-a/b->q1
q0-b/a->q1
q1-a/R->q0
q1-b/R->q0
q0-#/#->h
%
########################################################################
