Main algo fixed, next up is fixing our DFA.