Answers for "remove duplicate elements from two lists in c#"

C#
1

c# list remove duplicate items

List<string> lstWhitDuplicate = new list<string>();
lstWhitDuplicate.add("hallo");
lstWhitDuplicate.add("hallo");
lstWhitDuplicate.add("World");

List<string> lst = lstWhitDuplicate.Distinct().ToList(); 

// output lstWhitDuplicate:
// hallo hallo world
// output lst:
// hallo word
Posted by: Guest on August-14-2021
0

c# remove duplicates from list

List<T> withDupes = LoadSomeData();
List<T> noDupes = withDupes.Distinct().ToList();
Posted by: Guest on November-04-2021

Code answers related to "remove duplicate elements from two lists in c#"

C# Answers by Framework

Browse Popular Code Answers by Language