#include <stdio.h>
#include <time.h>
#include <stdlib.h>
int
main (void)
{
srand (time(NULL));
printf("RAND_MAX = %d\n", RAND_MAX);
printf ("A number between 0 and RAND_MAX : %d\n", rand());
printf ("A number between 0 and 99: %d\n", rand() % 100);
printf ("A number between 0 and 9: %d\n", rand() % 10);
printf ("A number between 1 and 6: %d\n", (rand() % 6) + 1);
return (0);
}