Delegate Example From C# In Depth Confusion
<p>I am looking at this example: </p>

<pre><code>List&lt;Product&gt; products = Product. GetSampleProducts() ;
products.Sort(
    (first, second) =&gt; first.Name.CompareTo(second. Name)
) ;
foreach (Product product in products)
{
    Console. WriteLine(product) ;
}
</code></pre>

<p>What function is actually called in the API when you do that?  Does the compiler create a class which implemnents the IComparer interface?</p>

<p>I thought delegates were anonymous methods - Here it seems to be an anonymous interface implementation which is casuing confusion</p>
