On Tuesday, 15 July 2014 at 02:49:56 UTC, WhatMeWorry wrote:
Sorry if this is an incredibly naive question.

I prefer to pragmatically pause my programs periodically so that I can peruse output statements. Ideally, I'd like to continue by just hitting any old key. My feeble attempt below requires I enter at least one character and then the enter key.

char ignore;
writeln("Enter to continue");
readf(" %s", &ignore);

Is there a way to continue with any old key press? or just the enter key?

Thanks in advance.


getch() reads any key and continues;

On Windows you can pipe you executable with the "more" command to pause after each page: your.exe | more

Reply via email to