list to set and and list in c# code example Example: make a list c# IList<int> newList = new List<int>(){1,2,3,4};