You need to put a "PAUSE" so you can see like:

i am not sure how it works in C but in C++ it is like this

system("PAUSE >nul");
return EXIT_SUCCESS;
}