Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
Re^2: Common Substringsby Anonymous Monk |
on Nov 15, 2005 at 11:19 UTC ( [id://508549]=note: print w/replies, xml ) | Need Help?? |
Thanks! It took me a bit to understand that you were using a bisection method. But I agree that it should be reasonably efficient. I just have a tendency to avoid substr() since it always feels like a very expensive call. The strings that I am spliting are paths, and because my sub then looks for the place of a slash, which should be 8 bits, I think that it is safe for me to use a binary method.
In Section
Seekers of Perl Wisdom
|
|