I recommend taking a look at the "longest common substring" section of this page on Dynamic Programming. These algorithms are pretty simple, and pretty fast.
Note that this type of iteration would benefit massively from converting to C - I'd recommend using Inline::C to convert just that one function.
(If time permits over the weekend I might have a go at that. But it'd be nice to have a decent data set to test it against.)
Hugo
In reply to Re: Search for identical substrings
by hv
in thread Search for identical substrings
by bioMan
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |