1.

Solve : Terminating a C++ file with control Z?

Answer» HEY guys, im trying to end my program with control Z,

problem is i have my main() in a loop so i input control Z it just keeps PRINTING lines till it crashes.

i want to do something like:

while (input != controlZ)
(
....
)

although im not sure if this is possible.. any ideas?
Maybe Control Z is filtered by the SYSTEM.
Ty it with some other char and see what happens.
Also, what input/output library did you declare?iostream and string.

my problem is

while (input != controlZ)

because i doubt that is the actual syntax.

if you can help me with this syntax is should be ABLE to figure out the rest

THANKS!


Discussion

No Comment Found