产生一个a到b之间的随机数,VB代码如何书写,保留一位小数,

问题描述:

产生一个a到b之间的随机数,VB代码如何书写,保留一位小数,

Private Sub Command1_Click() Print GetRdm(6.7, 14.7)End SubPrivate Function GetRdm(minNum As Single, maxNum As Single) As Single GetRdm = Format((maxNum - minNum) * Rnd + minNum, "#0.#")End Functi...