description | title | ms.date | dev_langs | ms.assetid | ||
---|---|---|---|---|---|---|
Learn more about: Eliminate Duplicate Elements from a Sequence |
Eliminate Duplicate Elements from a Sequence |
03/30/2017 |
|
2b224a84-bad5-4843-adcc-14e784d280f5 |
Use the xref:System.Linq.Queryable.Distinct%2A operator to eliminate duplicate elements from a sequence.
The following example uses xref:System.Linq.Queryable.Distinct%2A to select a sequence of the unique cities that have customers.
[!code-csharpDLinqQueryExamples#36] [!code-vbDLinqQueryExamples#36]