leo*_*ora 5 c# linq collections datetime
如果我有3个来自不同来源的DateTime列表
List<Datetime> list1 = GetListOfDates();
List<Datetime> list2 = GetAnotherListOfDates();
List<Datetime> list3 = GetYetAnotherListOfDates();
Run Code Online (Sandbox Code Playgroud)
返回所有3个列表中存在的DateTime列表的最快方法是什么.有一些LINQ声明吗?
List<DateTime> common = list1.Intersect(list2).Intersect(list3).ToList();
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
79 次 |
| 最近记录: |