repositories
/
TD_IML.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
15b351b373a47e26202abb2a4d0b8eed3ce80941
[TD_IML.git]
/
TD1
/
part_three
/
balle
/
balle.c
1
#include <sys/types.h>
2
#include <sys/wait.h>
3
4
#include <stdio.h>
5
#include <stdlib.h>
6
#include <string.h>
7
#include <unistd.h>
8
#include <time.h>
9
10
int
main
() {
11
12
srand
(
time
(
NULL
));
13
int
randvalue
=
rand
() %
5
+
1
;
14
15
printf
(
"[%d] Je suis la balle et je vole
\n
"
,
getpid
());
16
17
sleep
(
randvalue
);
18
19
return
randvalue
;
20
}