title: .NET converting simple arrays to List Generics
body: <p>I have an array of any type <code>T</code> (<code>T[]</code>) and I want to convert it into a List generic (<code>List&lt;T&gt;</code>). Is there any other way apart from creating a Generic list, traversing the whole array and adding the element in the List?</p>
  <p><strong>Present Situation:</strong></p>
  <pre><code>string[] strList = {&quot;foo&quot;,&quot;bar&quot;,&quot;meh&quot;};
  List&lt;string&gt; listOfStr = new List&lt;string&gt;();
  foreach(string s in strList)
  {
      listOfStr.Add(s);
  }
  </code></pre>
  <p><strong>My ideal situation:</strong></p>
  <pre><code>string[] strList = {&quot;foo&quot;,&quot;bar&quot;,&quot;meh&quot;};
  List&lt;string&gt; listOfStr = strList.ToList&lt;string&gt;();
  </code></pre>
  <p><strong>Or:</strong></p>
  <pre><code>string[] strList = {&quot;foo&quot;,&quot;bar&quot;,&quot;meh&quot;};
  List&lt;string&gt; listOfStr = new List&lt;string&gt;(strList);
  </code></pre>
  <p>I am suggesting the last 2 method names as I think compiler or <code>CLR</code> can perform some optimizations on the whole operations if It want inbuilt.</p>
  <p>P.S.: I am not talking about the <code>Array</code> or <code>ArrayList</code> Type</p>