I need a function which would generate a random integer in given range (including border values). I don\'t unreasonable quality/randomness requirements, I have four requirem
The formula for this is very simple, so try this expression,
int num = (int) rand() % (max - min) + min; //Where rand() returns a random number between 0.0 and 1.0