已知Random.Next(1,10),产生1至100不重复的随机数据(2)
来源:未知 责任编辑:责任编辑 发表时间:2015-01-01 13:17 点击:次
	   
	count = 2;
continue;
}
if (ary[index - 1] == 0 && currentIndex != index - 1)
{
ary[index - 1] = ary[currentIndex];
ary[currentIndex] = index;
currentIndex = index - 1;
count++;
}
else
{
while (k < 100 && ary[k] > 0)
{
k++;
}
if (currentIndex != k && k < 100)
{
ary[k] = ary[currentIndex];
ary[currentIndex] = k + 1;
currentIndex = k;
count++;
}
相关新闻>>
最新推荐更多>>>
              
          - 发表评论
 - 
				
 
- 最新评论 进入详细评论页>>
 



