摘要: C# 方法默认访问级别 : private C# 类默认访问级别 : internalpublic:访问不受限制。protected:访问仅限于包含类或从包含类派生的类型。Internal:访问仅限于当前程序集。protected internal:访问限制到当前程序集或从包含派生的类型的类别。pr 阅读全文
posted @ 2016-10-18 13:33 FredGrit 阅读(1334) 评论(1) 推荐(0) 编辑
摘要: static void Main(string[] args) { int[] arr = { 1, 3, 3, 3, 3, 4, 5, 4, 5, 8, 9, 3 }; //不重复 var unique = arr.GroupBy(o => o).Where(g => g.Count() == 1 阅读全文
posted @ 2016-10-18 00:28 FredGrit 阅读(655) 评论(0) 推荐(0) 编辑
摘要: static List<int> Given50RandomNumbers() { List<int> intList = new List<int>(); for(int i=1;i<=50;i++) { intList.Add(i); } if(intList.Count>0) { return 阅读全文
posted @ 2016-10-18 00:18 FredGrit 阅读(677) 评论(0) 推荐(0) 编辑