title: Why ICollection index does not work when instantiated?
body: <p>When we declare a parameter as ICollection and instantiated the object as List, why we can't retrive the indexes?  i.e.</p>
  
  <pre><code>ICollection&lt;ProductDTO&gt; Products = new List&lt;ProductDTO&gt;();
  Products.Add(new ProductDTO(1,"Pen"));
  Products.Add(new ProductDTO(2,"Notebook"));</code></pre>
  
  <p>Then, this will not work:</p>
  
  <pre><code>ProductDTO product = (ProductDTO)Products[0];</code></pre>
  
  <p>What is the bit I am missing?<br>
  [Yes, we can use List as declaration an it can work, but I don't want to declare as list, like:     </p>
  
  <pre><code>List&lt;ProductDTO&gt; Products = new List&lt;ProductDTO&gt;();</code></pre>
  
  <p>]</p>