java基础学习系列三

产生随机数

例如

[a,b]

Math.random*(b-a+1)+a

公式推算

[3,55]-----[0,52]+3

*53+3

原文地址:https://www.cnblogs.com/liubaihui/p/8320174.html