Windows下return 0;
或exit();
都不能达到直接关闭应用程序窗口的效果,怎样才能跳过press any key to continue呢?
阿神2017-04-17 11:40:06
Because your program does not run independently, but is run by another software (such as IDE). This software implements a feature called "Let the running program not close the window immediately after execution, but wait for press any key.”
高洛峰2017-04-17 11:40:06
No need to close the window when using the linux command line, press any key to continue
I don't know if it can be solved either.
I don’t think it’s realistic to solve this problem. The automatic shutdown you want is to wait until you finish running.
There is a kind of automatic closing called flashing by. You can't see it at all. Is it troublesome to press enter?