exu 3, key.ex
- Posted by ChrisBurch2 <crylex at freeuk.co.uk> Jun 19, 2006
- 697 views
Hi
integer code puts(1, "Press any key. I'll show you the key code. Press q to quit\n\n") while 1 do code = get_key() if code != -1 then printf(1, "The key code is: %d\n", code) if code = 'q' then exit end if end if end while
works
integer code puts(1, "Press any key. I'll show you the key code. Press q to quit\n\n") while 1 do code = get_key() if code != -1 then printf(1, "The key code is: %d\n", code) if code = 'q' then exit end if else printf(1, "\n", {}) end if end while
seg faults ?? Chris