title: C# lambda - keys array to values array
body: <p>How can the following <code>GetValues</code> method be implemented using lambda expression?</p>
  
  <pre><code>public object[] GetValues(string[] keys, Dictionary&lt;string, object&gt; map) 
  {
      // A simple non-lambda implementation
      object[] values = new object[keys.Length];
      for (int i = 0 ; i &lt; keys.Length ; i++) 
      {
          values[i] = map[keys[i]];
      }
      return values;
  }
  </code></pre>