I have this code:
#include <stdio.h>
#include <unistd.h>
int main()
{
while(1)
{
fprintf(stdout,"hello-out");
fprintf(stderr,"hello-err");
sleep(1);
}
return 0;
}
The output is hello-err
hello-err
hello-err
hello-err
hello-err
hello-err
at 1 sec intervals.
I want to know why hello-out never gets printed.