Anyone have a quick method for de-duplicating a generic List in C#?
If you're using .Net 3+, you can use Linq.
List<T> withDupes = LoadSomeData(); List<T> noDupes = withDupes.Distinct().ToList();
2.1m questions
2.1m answers
60 comments
57.0k users