Implementations of automata algorithms in Prolog