From: John Joyce Date: 2007-07-23T12:03:11+09:00 Subject: Re: Boyer-Moore string search algorithm in ruby On Jul 22, 2007, at 1:04 PM, Peter Seebach wrote: > In message > , > "Nobuyoshi Nakada" wr > ites: >> At Sun, 22 Jul 2007 12:25:01 +0900, >> bcparanj@gmail.com wrote in [ruby-talk:261195]: >>> Does anyone know if this is already part of Ruby open source >>> library? >>> I did not find anything on Google. TIA. > >> String#index uses Karp-Rabin algorithm, not Boyer-Moore. > > That strikes me as secondary; presumably, the goal is to implement > it in Ruby > code, not to determine what algorithm the language internals use, no? > > -s > Perhaps if you look into the code for one of those functions, you might find that it is done in Ruby, you might not.