Click here to Skip to main content
15,891,253 members
Articles / All Topics

How to Use LINQ to Get a Count of Duplicates in a List

19 May 2009 429  
Often we have to get a count of duplicate items in a list. An easy way to do this is to group the list on the property we want to count, then use LINQ&#39;s GroupBy&#39;s Count feature. Below is a quick example using an employee list.  private static void Main() {     List<Employee> empLi
We're sorry, but the article you are trying to view was deleted at 19 May 2009.

Please go to the All Topics Table of Contents to view the list of available articles in this section.