Does anyone know why if i put a printf just before a delay it waits until the delay is finished before it prints de message?
Code1 with sleep():
int
Normally, standard output is buffered until you either:
\n
fflush(stdout)
Do one of these things before calling delay() and you should see your output.
delay()