in reply to Re: Finding all substrings
in thread Finding all substrings

I disagree. The root of optimization is finding a solid algorithm, implementing it, tuning it and then finding a way to exploit caching to make it faster. See my solution below for an example. See Memoize for another option.

-sam