title: Search for a little string in a huge one
body: <p>I'm working on a project in which I must search for a little string (about 40 chars) in a very very large string (we're speaking of about a hundred million chars). I'm searching the fastest way. I've tried several methods: these are the results of benchmarks:</p>
  
  <ul>
  <li><code>Contains</code> returned <code>True</code> in <strong>248 ms</strong>; </li>
  <li><code>IndexOf</code> returned <code>True</code> in <strong>671 ms</strong> (I would have never said that!); </li>
  <li><code>Contains</code> using an array instead of a string returned <code>True</code> in <strong>48 ms</strong> only;</li>
  </ul>
  
  <p>Even though the <code>Contains</code> inside an array seemed to be the best method, I've had a look at some search algoritms too (<a href="http://en.wikipedia.org/wiki/Knuth%E2%80%93Morris%E2%80%93Pratt_algorithm" rel="nofollow">Knuth–Morris–Pratt</a>, <a href="http://en.wikipedia.org/wiki/Rabin%E2%80%93Karp_algorithm" rel="nofollow">Rabin-Karp</a> and <a href="http://en.wikipedia.org/wiki/Boyer%E2%80%93Moore_string_search_algorithm" rel="nofollow">Boyer-Moore</a>), but none of them seems to be suitable for my scenario</p>
  
  <p>My question is: is there a faster way to search a little string in a very big string?</p>
  
  <p>Thanks,</p>
  
  <p><em>PWhite</em></p>