List<int> list = new List<int>();
list.Add();
list.Add();
list.Add();
list.AddRange(new int[] { , , , , , });
int[] nums=list.ToArray(); //集合转数组
for (int i = ; i < list.Count; i++)
{
Console.WriteLine(list[i]);
}
char[] chs = new char[] { 'a','b','c'};
List<char> listchar = chs.ToList();//char 类型数组转集合
for (int i = ; i < list.Count; i++)
{
Console.WriteLine(listchar[i]);
}
Console.ReadLine();