各位大佬,我这里为啥会报错呢?
```random rand3=new random();
int one=rand3.nextInt(10);
int two=rand3.nextInt(10);
int three=rand3.nextInt(10);
int four=rand3.nextInt(10);
int five=rand3.nextInt(10);
System.out.println(one+1);
报错的点在后面rand3.nextInt(10);这片
我上面有一段和这里类似的就不会报错
```Random rand = new Random();
int month = rand.nextInt(12);
这段代码就没有报错,想问下是为什么呢?感谢大家