Sampson-Li
Sampson.Li学习经验总结博客 学历代表过去,能力代表现在.学习力代表未来!
摘要: 在开发过程中.数组和集合的处理是最让我们担心.一般会用for or foreach 来处理一些操作.这里介绍一些常用的集合跟数组的操作函数.首先举例2个集合A,B.List<int> listA = new List<int> {1,2,3,5,7,9};List<int> listB = new List<int> {13,4,17,29,2};listA.AddRange(listB);把集合A.B合并List<int> Result = listA.Union(listB).ToList<int>(); //剔除重复 阅读全文
posted @ 2011-11-09 12:01 Sampson 阅读(62928) 评论(0) 推荐(4) 编辑