step20
|
Kasai's algorithm for constructing longest common prefix array. More...
#include <suffix_array.hpp>
Public Member Functions | |
std::span< const Size > | lcp_array () const |
enhanced_suffix_array (suffix_array< Char, Size, Compare > &&arr) | |
template<std::ranges::input_range R> | |
enhanced_suffix_array (R &&r, const Compare &comp={}) | |
![]() | |
const Char * | data () const |
Size | size () const |
Size | operator[] (Size n) const |
suffix position | |
const Compare & | comp () const |
virtual | ~suffix_array ()=default |
suffix_array (std::basic_string< Char > str, const Compare &comp={}) | |
template<std::ranges::input_range R> | |
suffix_array (R &&r, const Compare &comp={}) | |
std::span< const Size > | find (std::ranges::input_range auto &&str) const |
Find positions of suffixes starting with substring. | |
Additional Inherited Members | |
![]() | |
using | value_type = Char |
using | size_type = Size |
Kasai's algorithm for constructing longest common prefix array.
Time and space complexity O(N), where: N - text length.
|
inlineexplicit |
|
inlineexplicit |
|
inline |