add adaptive search algorithm

horspool runs runs in O(textlen / patternlen + patternlen)
naive search runs O(textlen)

in the average case.
Based on the benchmarks a formula was derived to select the
best algorithm for a given textlen and patternlen.