Suffix Automaton Algorithm

For example, the suffix automaton of the string" suffix" accepts the strings" suffix"," uffix"," ffix"," fix"," ix"," X" and the empty string. The term suffix automaton is also sometimes used for any automaton recognizing suffixes of a text.

Suffix Automaton source code, pseudocode and analysis