title: Getting odd/even part of a sequence with LINQ
body: <p>Say I have a list of all <code>Projects</code>, and that I group them by <code>Category</code> like this:</p>
  <pre><code>var projectsByCat = from p in Projects
                      group p by p.Category into g
                      orderby g.Count() descending
                      select new { Category = g.Key, Projects = g };
  </code></pre>
  <p>Now I want to display this as a list in a web page, where first I create the left side div, secondly the right side div. I am ordering by number of <code>Projects</code> in each <code>Category</code> to show the <code>Categories</code> with the most <code>Projects</code> on top - thus I would like to split <code>projectsByCat</code> in two - if I put all the &quot;odd numbered&quot; <code>Categories</code> on the left and the &quot;even numbered&quot; categories on the right, I think I will get a reasonably sane view.</p>
  <p>So I thought I could do this to get the odd and even members of <code>projectsByCat</code>:</p>
  <pre><code>var oddCategories = projectsByCat.Where((cat, index) =&gt; index % 2 != 0);
  
  var evenCategories = projectsByCat.Where((cat, index) =&gt; index % 2 == 0);
  </code></pre>
  <p>And it compiles - however, when I run it, I get an exception such as this:</p>
  <blockquote>
  <p>Unsupported overload used for query operator 'Where'.</p>
  </blockquote>
  <p>And I thought I was safe since it compiled in the first place.. ;)</p>
  <p>Is there an elegant way to do this? And also, is there an elegant explanation for why my creative use of <code>Where()</code> won't work?</p>