为什么会报错,求大神教!!!(PS:想生成某个范围的随机数)
是不是Random对象初始化有错? 要怎么改才对啊?
怪我咯2017-04-17 17:59:51
Your randoms are all null, and you will definitely get an error... You need to create a new Random object and assign it to random:
Random random = new Random();
// 其他代码
伊谢尔伦2017-04-17 17:59:51
You must have obsessive-compulsive disorder when writing code! For example, seeing warnings makes you feel uncomfortable. . . .