I have a List of integer tuple
List<Tuple<int, int>> list = new List<Tuple<int, int>>();
list.Add(new Tuple<int, int>(1,12));
list.Add(new Tuple<int, int>(1,2));
list.Add(new Tuple<int, int>(1,18));
list.Add(new Tuple<int, int>(1,12));
I want to remove the redundant value of item2 which is 12 in this case
The updated list should also be List>. (same type) but with distinct values.The new tuple of type List> should contain only following:
list.Add(new Tuple<int, int>(1,2));
list.Add(new Tuple<int, int>(1,18));
list.Add(new Tuple<int, int>(1,12));
Any help?