docs: def compile(self):
          """Return python code for create and execute machine."""
          result = TEMPLATE
          result += 'machine = Machine(' + repr(self.alphabet) + ')\n'
  
          for state in self.states:
              repr_state = state[0]
              for rule in self.states[state]:
                  repr_state += ' ' + (','.join(rule) if rule is not None else '-')
  
              result += ("machine.add_state({repr_state})\n".format(repr_state=repr(repr_state)))
  
          result += "for line in stdin:\n"
          result += "    print(machine.execute(line))"
          return result