-
Knuth-Morris-Pratt
receives two strings: Text - a string representing the text to be searched (length n) Target - the string to be found (length m)
returns the first index in Text that Target appears in or -1 if no matching string was found.
works in Θ(n) with preparation time of Θ(m)
Request

