APL/APL1.1/CM2/lancer.c

17 lines
334 B
C
Raw Normal View History

2022-01-25 15:13:52 +01:00
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(int argc, char const argv[])
{
FILE *flux;
int temp=0;
flux = fopen("/dev/random", "r");
if(flux)
{
fread(&temp,sizeof(int),1,flux);
printf("%d\n", temp%6);
fclose(flux);
}
return EXIT_SUCCESS;
}