#include <stdio.h> #include <stdlib.h> #include <time.h> int main(void) { srand(time(NULL)); printf("rand = %d", rand() % 7); }