Q
quickcur
Hi, I am using the int version of rand() with MS Visual Studio. I would
like to generate random number in the range of [0, 99]. Right now I am
using
rand() * 100 / (RAN_MAX + 1)
I found that I got too much 0. 0 appears more than any other numbers.
How can I fix it?
Thanks,
qq
like to generate random number in the range of [0, 99]. Right now I am
using
rand() * 100 / (RAN_MAX + 1)
I found that I got too much 0. 0 appears more than any other numbers.
How can I fix it?
Thanks,