Preventing console window from closing on Visual Studio C/C++ Console application

前端 未结 21 2070
灰色年华
灰色年华 2020-11-21 23:42

This is a probably an embarasing question as no doubt the answer is blindingly obvious.

I\'ve used Visual Studio for years, but this is the first time I\'ve done any

21条回答
  •  南旧
    南旧 (楼主)
    2020-11-22 00:00

    If you run without debugging (Ctrl+F5) then by default it prompts your to press return to close the window. If you want to use the debugger, you should put a breakpoint on the last line.

提交回复
热议问题