Re: divide & conquer algorithm to implement string matching



misterio <giagimari@xxxxxxxxx> writes:

On 30 Mag, 14:43, Pascal Bourguignon <p...@xxxxxxxxxxxxxxxxx> wrote:
It's called "divide and conquer", not "divide by 2 and conquer".
I know that,I choose 2 just because it's the simplest one.Do you mean
that It could be better if I choose another one?

Yes, you could choose 1 and n-1. It works as well, and can easily be
converted into an iteration instead of a recursion.

--
__Pascal Bourguignon__ http://www.informatimago.com/

NOTE: The most fundamental particles in this product are held
together by a "gluing" force about which little is currently known
and whose adhesive power can therefore not be permanently
guaranteed.
.