/// <summary> /// 打乱顺序 /// </summary> /// <param></param> /// <returns></returns> public List<int> suiji(List<int> list) { Random rnd = new Random(); for (int i = 0; i < list.Count; i++) { int temp = list[i]; int j = rnd.Next(0, list.Count-1); list[i] = list[j]; list[j] = temp; } return list; }
微信抢红包ASP.NET代码轻松实现(2)
内容版权声明:除非注明,否则皆为本站原创文章。