C-输出屏幕在VS2013中突然消失


#include<stdio.h>
#include<conio.h>
int main()
{
    printf("Hello world");
    getch();
    return 0;
}

我正在使用C语言编写一个简单的Hello World应用程序,但是当我运行程序时,输出屏幕会闪烁并突然消失?

getch()(即使使用_etch())也将读取stdin。但是编译器可能正在优化函数,并且永远不会被称为结束程序。

编辑:根据MSDN。

最新更新