摘要: // 实现多key分组的扩展函数版本var sums = empList .GroupBy(x => new { x.Age, x.Sex }) .Select(group => new { Peo = group.Key, Count = group.Count() });foreach (var employee in sums) { Console.WriteLine(employee.Count + ": " + employee.Peo);}// 实现多key分组的lambda版本var sums2 = fro... 阅读全文
posted @ 2013-04-10 20:04 smodi 阅读(167) 评论(0) 推荐(0) 编辑