您的位置:首页 > 其它

如何产生一定范围内的随机数

2009-03-17 14:59 211 查看
 1. Random   t   =   new   Random();        int   i   =   5   +   t.nextInt(5);     //   5~10     2. public   int   getRandom(int   min,   int   max)   {           return   (random.nextLong()
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  random