SortList<int,int> sl=new SortList<int,int>(); sl.Add(5,100); sl.Add(1,102); foreach(var sle in sl){ Console.WriteLine(sle.value); }