working boolean and digit DFAs