Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Viewing all articles
Browse latest Browse all 22017

Cygwin gcc compiling and running, but doesn't printf anything

$
0
0

I'm just starting with C and installed Cygwin with GCC compiler on Windows. I tried running this Hello World program.

#include <stdio.h>

int main(void)
{

    //fflush(stdout);
    //setlinebuf(stdout);
    //setbuf(stdout, 0);
    printf("Hello World!\n");
    return 0;
}

The code compiles fine but when I try running it with ./ there is no output. I have tried to fix it using the commented lines (obviously I uncommented before running) but still had no output.


Viewing all articles
Browse latest Browse all 22017

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>