I have various menus in my program, and I would like the user to be able to press for example the key "ESC" at any moment so that he'd return to the main menu. I would know how to include this option in every menu (just adding one option at the end), but I want to be able to go back to the main menu at any moment. For example, if the user is entering new data for a new project, but he changes his mind, now he'd have to finish writing data (even if it useless).
I've had a look thgough the two books I have, and through the help file from the compiler (Turbo C++ 3.0) but I couldn't find anything.
It's not homeworking, just curiosity
Any simple ideas?