implemented Automaton.substitute(Char,String)