title: LINQ C# Selecting characters from string
body: <p>I have a string that I convert to a char array and then I use LINQ to select the different characters inside the char array and then order them by Descending but only catch the characters, not the punctuation marks etc...</p>
  <p>Here is the code:</p>
  <pre><code>string inputString = &quot;The black, and, white cat&quot;;
  var something = inputString.ToCharArray();
  var txtEntitites = something.GroupBy(c =&gt; c)
                     .OrderByDescending(g =&gt; g.Count())
                     .Where(e =&gt; Char.IsLetter(e)).Select(t=&gt; t.Key);
  </code></pre>
  <p>And the error message I get:</p>
  <ul>
  <li><p>Error CS1502: The best overloaded method match for `char.IsLetter(char)' has some invalid arguments (CS1502)</p>
  </li>
  <li><p>Error CS1503: Argument '#1' cannot convert 'System.Linq.IGrouping&lt;char,char&gt;' expression to type `char' (CS1503)</p>
  </li>
  </ul>
  <p>Any ideas? Thanks :)</p>