怎么让编译出来的程序,运行完不要立即关闭
如何让编译出来的程序,运行完不要立即关闭?
#include "iostream"
using namespace std;
int main(int argc, char* argv[])
{
cout<<"Lingcong"<<endl;
return 0;
}
双击编译出来的程序(Debug文件夹里),不要让窗口立即关闭?
------解决方案--------------------
getchar();
或者
system("pause");
#include "iostream"
using namespace std;
int main(int argc, char* argv[])
{
cout<<"Lingcong"<<endl;
return 0;
}
双击编译出来的程序(Debug文件夹里),不要让窗口立即关闭?
------解决方案--------------------
getchar();
或者
system("pause");