title: Using Linq to select subset from a Dictionary<string, int>?
body: <p>I'm newer to <code>C#</code> and I'm trying to use LINQ (or another method?) to select a subset of a <code>Dictionary&lt;string, int&gt;</code> object where the value (<code>int</code>) is greater than 5.</p>
  
  <pre><code>+-------------+------------+
  | Key(string) | Value(int) |
  +-------------+------------+
  |         000 |          0 |
  |         111 |          1 |
  |         222 |          2 |
  |         333 |          3 |
  |         444 |          4 |
  |         555 |          5 |
  |         666 |          6 |
  |         777 |          7 |
  |         888 |          8 |
  |         999 |          9 |
  +-------------+------------+
  </code></pre>
  
  <p>I created the dictionary object above with this code to simply fill a dictionary with some data:</p>
  
  <pre><code>        Dictionary&lt;string, int&gt; linkCounter = new Dictionary&lt;string, int&gt;();
  
          for (int i=0; i&lt;=9; i++)
          {
              string key = i.ToString() + i.ToString() + i.ToString();
              for (int n=0; n&lt;=i; n++)
              {
                  if (linkCounter.ContainsKey(key))
                  {
                      linkCounter[key]++;
                  }
                  else
                  {
                      linkCounter.Add(key, 0);
                  }
              }
          }
  </code></pre>
  
  <p>How can I do something equivalent to:</p>
  
  <blockquote>
    <p><code>foreach (KeyValuePair&lt;string, int&gt; kvp in linkCounter</code> <strong>[where kvp.value > 5]</strong><code>)</code></p>
  </blockquote>