Suffix tree: Difference between revisions
m
→{{header|Raku}}: Fix link: Perl 6 --> Raku
SqrtNegInf (talk | contribs) m (→{{header|Sidef}}: Fix link: Perl 6 --> Raku) |
SqrtNegInf (talk | contribs) m (→{{header|Raku}}: Fix link: Perl 6 --> Raku) |
||
Line 1,010:
Here is quite a naive algorithm, probably <math>O(n^2)</math>.
The display code is a variant of the [[visualize_a_tree#
<lang perl6>multi suffix-tree(Str $str) { suffix-tree flat map &flip, [\~] $str.flip.comb }
|