I have a List which can contain duplicates. So because of that reason I want to delete all the duplicates. I know, that I can do this with the Distinct() Method like this:
myList.Distinct().ToList();
But I have to edit the item in the list, which was the one don't removed from Distinct().
Example: myList looks like this:
(1,'A', "Normal"),
(2,'B', "Normal"),
(3,'A', "Normal"),
(4,'C', "Normal"),
(5,'C', "Normal"),
(6,'A', "Normal");
And the result of this should be following:
(1,'A', "Multiple"),
(2,'B', "Normal"),
(4,'C', "Multiple")
Edit:
I also know, that I can do it with GroupBy. Then I also have all items only one time in my list:
myList.GroupBy(x => x.Letter).Select(x => x.First()).ToList();