Tag Archives: The console

Solve the problem of visual studio console flashback

On the top navigation bar, click “Project” ->; “Properties” – & gt; ‘Configure Properties’ –>; “Linker” –>; “System” – & gt; “Subsystems (there is a drop-down icon on the right side of the window)” –>; SUBSYSTEM:CONSOLE -> drop down box select ‘/SUBSYSTEM:CONSOLE’ -> Finally “confirm” –>; Click on the top right corner of “File” –>; “Save it all.”

[vs console program flashback]


Today, when I was writing a program, I encountered a problem with VS console program flashing back. So I Googled it and found the following solutions:
Before the return, add system(” PAUSE “); PAUSE is case-insensitive; Add getchar() before return; Project – & gt; Property – & gt; Configure properties ->; The linker – & gt; System – & gt; Subsystem – & gt; SUBSYSTEM adds the “/SUBSYSTEM:CONSOLE” link option and just configure it
Three methods have been tried, can use ~

Visual studio console program output window flashed by

Write at the front:
This blog post introduces a little annoying problem solving that isn’t a bug. Programming with Visual Studio often uses the console output window, but there is always a situation where the window flashes past and it is difficult to see the output of the program. Here, I write a blog post to record it, so as not to forget or make similar mistakes in the same type of problem.
Solution:
1. In the last line of the program, return 0, add system(” pause “) or getchar(); It solves some problems, which I often do when I do some OJ tests in order to test in my IDE;
2. Don’t Press F5 to run the program, Ctrl + F5 instead, a window will be displayed like this: “Press any key tocontinue…” The words. The reason is that F5 is in Debugging mode, while CTRL +F5 is in Start Without Debugging mode. I found this on the Internet. Can really solve the problem, but their lack of practical theoretical knowledge to support, so in the future to read a lot of attention to the process.