我正在使用.NET 3.5.为什么我仍然会得到:
不包含'Distinct'的定义
使用此代码:
using System.Collections.Generic;
//.. . . . . code
List<string> Words = new List<string>();
// many strings added here . . .
Words = Words.Distinct().ToList();
Run Code Online (Sandbox Code Playgroud)