4 回答
冰山点水
TA贡献109条经验 获得超149个赞
package com.imooc; import java.util.Random; public class RandomNumber { public static void main(String[] args) { Random ran = new Random(); int[] num = new int[10]; for (int i = 0; i < num.length; i++) { num[i] = ran.nextInt(100) + 1; System.out.println(num[i]); } } }
添加回答
举报
0/150
提交
取消