Could someone change this to C++ for me thanks.
Code:Randomize
number = CInt(49 * Rnd())
Printable View
Could someone change this to C++ for me thanks.
Code:Randomize
number = CInt(49 * Rnd())
This should do...
Code:#include <time.h>
int number;
srand( (unsigned)time( NULL ) ); // Setup the random number routine
number=rand() % 9; // Create random number between 0 and 9
Thanks that was exactly what i was looking for.
Glad to hear! :)
Also....
www.softseek.com - Programming section has converters for this kinda stuff :)