Concepts7
Suffix Array Construction
A suffix array stores the starting indices of all suffixes of a string in lexicographic order, enabling fast substring queries and many string operations.
Lyndon Factorization
A Lyndon word is a string that is strictly smaller (lexicographically) than all of its nontrivial rotations.
Palindromic Tree (Eertree)
A Palindromic Tree (Eertree) stores every distinct palindromic substring of a string as a node and can be built online in linear time.
Suffix Automaton - Advanced Usage
A suffix automaton (SAM) is a compact DFA that captures all distinct substrings of a string and supports many advanced queries in linear time.
Suffix Automaton
A suffix automaton (SAM) is the minimal deterministic finite automaton that recognizes all substrings of a string, built online in O(n) time and space.
Aho-Corasick Automaton
AhoβCorasick is a trie with failure links that finds all occurrences of many patterns in a single pass over the text.
Suffix Array - LCP Array Applications
The LCP (Longest Common Prefix) array, built alongside a suffix array, unlocks fast solutions to problems like longest repeated substring, number of distinct substrings, and longest common substring.