Anonymous user
Library/C Runtime/ranged rand: Difference between revisions
no edit summary
(CRT component page.) |
No edit summary |
||
(3 intermediate revisions by the same user not shown) | |||
Line 1:
#include <cstdlib>
...
int rangedRand(int min, int max)
{
return rand() % (max - min + 1) + min;
}
|