摘要: 动手动脑: 一、编写一个方法,使用以上算法生成指定数目(比如1000个)的随机整数。 方法1(数据类型)(最小值+Math.random()*(最大值-最小值+1)) 例:(int)(1+Math.random()*(10-1+1)) 从1到10的int型随数 方法2获得随机数 for (int i 阅读全文
posted @ 2016-10-16 11:41 紫翼雪蝶 阅读(207) 评论(0) 推荐(0) 编辑