I am new at C++, but I am using dev-c++ on windows xp, which has c prompt, not dos. Every time I try to run my program, a console pops up and I try to input my information, for whatever i wrote the program to ask, and the window closes as soon as I hit enter. How do I fix this?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am new at C++, but I am using dev-c++ on windows xp, which has c prompt, not dos. Every time I try to run my program, a console pops up and I try to input my information, for whatever i wrote the program to ask, and the window closes as soon as I hit enter. How do I fix this?
Put this in your console App :
#include <stdlib.h>
system("PAUSE");
Put system("PAUSE") in the end of your code.