Subj : Re: String searching with a twist To : comp.programming From : Roger Willcocks Date : Sun Aug 07 2005 12:53 am "CBFalconer" wrote in message news:42F4B5FE.19D2DCB1@yahoo.com... > Roger Willcocks wrote: >> > ... snip ... >> >> Using a KMP search on a binary string isn't particularly helpful >> in any case since there are only two different symbols in the >> dictionary, so you don't get the full benefit of skipping past >> characters found in the target string that aren't in the search >> string. > > The important point about a KMP search is that it eliminates all > backtracking in the searched data, thus making it easy to search a > stream on the fly. > Scratches head, takes Sedgewick from shelf. Oops, I was thinking of Boyer-Moore. -- Roger .