Prevent external console from closing immediately


In CLion, there's the checkbox "Run in External Console", from the "Run/Debug Configurations". However, when trying to display a simple Hello World, the program opens, and then immediately closes, not letting me see anything. If I request an input from the user, the message is properly displayed, but the program still closes immediately.

Is there a way to stop this behavior, without changing the original code, and still using the external console?

1 comment


It's not implemented yet. Feel free to comment or upvote See if you are not familiar with YouTrack.

Meanwhile you san use system("pause") in your code.


Please sign in to leave a comment.