Hi,
I create random numbers with a C-function like that:
FILE *dev_random;
char rand_num[30];
int count = 0;
if ((dev_random = fopen("/dev/urandom","r"))== NULL)
print_error("Can't open /dev/random for
reading.");
fread(&rand_num,1,1,dev_random);
fclose(dev_random);
while (rand_num2[count] != '\0'){
count++;
printf("%i\n",rand_num2[count]);
}
return 0;
So it seems I'm getting numbers in the range of -126 upto 126. How can I
now randomly generate letters out of that?