warning C4242: 'function': conversion from 'time_t' to 'unsigned int', possible loss of data
#include<stdio.h>
#include<time.h>
#include<stdlib.h>
int main(void)
{
srand(time(0));
int lucky = (rand() % 26) + 65;
printf("> %d", lucky);
return 0;
}
I am expecting the program to output a random letter between uppercase A to uppercase Z.
The srand function seems to be working with other programs but not here. Not sure why.