J
jelly
Hello All
Part of the code I am working on requires that a loop exits upon the 'ENTER'
key being pressed.
I would have thought its possible by doing something like the following:
while(input != '\n')
...do something;
I tried this but it obviously does not work. So it seems I must use the
Ascii
value of 'ENTER' key to quit in the while loop. How do i do this? Thanks
much.
Part of the code I am working on requires that a loop exits upon the 'ENTER'
key being pressed.
I would have thought its possible by doing something like the following:
while(input != '\n')
...do something;
I tried this but it obviously does not work. So it seems I must use the
Ascii
value of 'ENTER' key to quit in the while loop. How do i do this? Thanks
much.