title: Scraping Google results c#
body: <p>I'm scraping Google results using <a href="https://www.nuget.org/packages/ScrapySharp/" rel="nofollow noreferrer">ScrapySharp.Extension</a> and <a href="https://www.nuget.org/packages/Newtonsoft.Json" rel="nofollow noreferrer">Newtonsoft.Json</a> for serialization and deserialization json results. I'm getting the results in form of text file, because results are encrypted. With regular expression and splitting I have removed the irrelevent stuff from my results but still there are so many irrelevent garbage in my array, I just need results. With every different query searched it gives different useless values. Is there any way to remove or clean my array? I just need results.</p>
  
  <pre class="lang-cs prettyprint-override"><code>string[] separatingChars = { "null", ",", "[", "]", "\\n", "/d", "true", "NCSR", "*", "\\", "//", "//n", "\\/", "/", "\"u", "\"e", "\"c", "\":", "\"p", "\"d", "\")", "\"", "}", "{", "\"0", "\"38", "\"69", "\"]", "[\"", "www.google.com.tr"};
  
  string[] words = result.Split(separatingChars, System.StringSplitOptions.RemoveEmptyEntries);
  System.Console.WriteLine("{0} substrings in words:", words.Length);
  </code></pre>
  
  <p>This is my result:</p>
  
  <pre><code>"{\"e\":\"h2TSV9rDD8fzUO2WkKgD\",\"c\":0,\"u\":\"https:\\/\\/www.google.com.tr\\/s?tbm=mapfp=1\\u0026gs_ri=maps\\u0026suggest=p\\u0026authuser=0\\u0026hl=en\\u0026pb=!2i2!4m12!1m3!1d10453.125285380847!2d29.0052447!3d41.047225649999994!2m3!1f0!2f0!3f0!3m2!1i914!2i667!4f13.1!7i20!10b1!12m6!2m3!5m1!2b0!20e3!10b1!16b1!19m3!2m2!1i392!2i106!20m44!2m2!1i203!2i100!3m1!2i4!6m6!1m2!1i86!2i86!1m2!1i408!2i256!7m30!1m3!1e1!2b0!3e3!1m3!1e2!2b1!3e2!1m3!1e2!2b0!3e3!1m3!1e3!2b0!3e3!1m3!1e4!2b0!3e3!1m3!1e8!2b0!3e3!1m3!1e3!2b1!3e2!2b1!4b1!9b0!22m3!1shWTSV8-xF4PjUf20tMAG!3b1!7e81!23m1!4b1!24m5!2b1!5m1!5b1!10m1!8e3!26m3!2m2!1i80!2i92!37m1!1e81!47m0!49m1!3b1\\u0026q=taksim\\u0026pf=p\\u0026tch=1\\u0026ech=9\\u0026psi=hWTSV8-xF4PjUf20tMAG.1473406074800.1\",\"p\":true,\"d\":\")]}'\\n[[\\\"taksim\\\",[[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[\\\"Taksim Square, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",null,null,null,1,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,\\\"BChIJY71WBmW3yhQRw7YgjLJYoIw\\\\u003d\\\",null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n,[\\\"Taksim Square\\\",[[0,6]\\n]\\n]\\n,[\\\"Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\"]\\n,0,0,null,null,[null,38,[69]\\n]\\n,null,null,null,[null,null,41.0370023,28.985091699999998]\\n,null,[[\\\"0x14cab7650656bd63:0x8ca058b28c20b6c3\\\",\\\"Taksim Square, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",null,[null,null,41.0370023,28.985091699999998]\\n,1,null,null,null,0]\\n,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n,[\\\"Taksim Square, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",\\\"0x14cab7650656bd63:0x8ca058b28c20b6c3\\\",[null,null,41.0370023,28.985091699999998]\\n]\\n]\\n]\\n,[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[\\\"Taksim, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",null,null,null,1,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,\\\"BChIJ08HkEGW3yhQRSdB1J8_42c8\\\\u003d\\\",null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n,[\\\"Taksim\\\",[[0,6]\\n]\\n]\\n,[\\\"Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\"]\\n,1,0,null,null,[null,38,[69]\\n]\\n,null,null,null,[null,null,41.0370485,28.9858443]\\n,null,[[\\\"0x14cab76510e4c1d3:0xcfd9f8cf2775d049\\\",\\\"Taksim, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",null,[null,null,41.0370485,28.9858443]\\n,0,null,null,null,0]\\n,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n,[\\\"Taksim, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",\\\"0x14cab76510e4c1d3:0xcfd9f8cf2775d049\\\",[null,null,41.0370485,28.9858443]\\n]\\n]\\n]\\n,[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[\\\"Harbiye Mahallesi, Taşkışla Caddesi, Şişli\\/İstanbul\\\",null,null,null,1,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n,[\\\"Taşkışla Caddesi\\\",[[0,16]\\n]\\n]\\n,[\\\"Harbiye Mahallesi, Şişli\\/İstanbul\\\"]\\n,0,0,null,null,[null,38]\\n,null,null,null,[null,null,41.0444781,28.9903408]\\n,null,null,[\\\"Harbiye Mahallesi, Taşkışla Caddesi, Şişli\\/İstanbul\\\"]\\n]\\n]\\n,[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[\\\"Taksim Station, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",null,null,null,1,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,\\\"BChIJO0h7PGW3yhQRD9N8fEEQZRI\\\\u003d\\\",null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n,[\\\"Taksim Station\\\",[[0,6]\\n]\\n]\\n,[\\\"Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\"]\\n,1,0,null,null,[null,38]\\n,null,null,null,[null,null,41.0367609,28.9864186]\\n,null,[[\\\"0x14cab7653c7b483b:0x126510417c7cd30f\\\",\\\"Taksim Station, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",null,[null,null,41.0367609,28.9864186]\\n,0,null,null,null,0]\\n,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n,[\\\"Taksim Station, Gümüşsuyu Mahallesi, Beyoğlu\\/İstanbul\\\",\\\"0x14cab7653c7b483b:0x126510417c7cd30f\\\",[null,null,41.0367609,28.9864186]\\n]\\n]\\n]\\n,[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,[[\\\"Rüstem Paşa Mahallesi, Tahmis Sokak, Fatih\\/İstanbul\\\",null,null,null,1,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n,[\\\"Tahmis Sokak\\\",[[0,12]\\n]\\n]\\n,[\\\"Rüstem Paşa Mahallesi, Fatih\\/İstanbul\\\"]\\n,0,0,null,null,[null,38]\\n,null,null,null,[null,null,41.016564699999996,28.9703786]\\n,null,null,[\\\"Rüstem Paşa Mahallesi, Tahmis Sokak, Fatih\\/İstanbul\\\"]\\n]\\n]\\n]\\n,null,null]\\n,null,null,null,null,null,null,\\\"h2TSV9rDD8fzUO2WkKgD\\\",null,null,null,null,null,null,null,null,null,null,null,null,null,null]\\n\"}/*\"\"*/{\"e\":\"h2TSV-yhEcfzUO2WkKgD\",\"c\":0,\"u\":\"https:\\/\\/www.google.com.tr\\/search?tbm=mapfp=1\\u0026gs_ri=maps\\u0026suggest=p\\u0026authuser=0\\u0026hl=en\\u0026pb=!2i2!4m12!1m3!1d10453.125285380847!2d29.0052447!3d41.047225649999994!2m3!1f0!2f0!3f0!3m2!1i914!2i667!4f13.1!7i20!10b1!12m6!2m3!5m1!2b0!20e3!10b1!16b1!19m3!2m2!1i392!2i106!20m44!2m2!1i203!2i100!3m1!2i4!6m6!1m2!1i86!2i86!1m2!1i408!2i256!7m30!1m3!1e1!2b0!3e3!1m3!1e2!2b1!3e2!1m3!1e2!2b0!3e3!1m3!1e3!2b0!3e3!1m3!1e4!2b0!3e3!1m3!1e8!2b0!3e3!1m3!1e3!2b1!3e2!2b1!4b1!9b0!22m3!1shWTSV8-xF4PjUf20tMAG!3b1!7e81!23m1!4b1!24m5!2b1!5m1!5b1!10m1!8e3!26m3!2m2!1i80!2i92!37m1!1e81!47m0!49m1!3b1\\u0026q=taksim\\u0026pf=p\\u0026tch=1\\u0026ech=9\\u0026psi=hWTSV8-xF4PjUf20tMAG.1473406074800.1\\u0026oq=taksim\",\"p\":true,\"d\":\"\\\"NCSR\\\"\"}/*\"\"*/"
  </code></pre>