Key Press Not Working

brandon wallace nodnarb at gmx.us
Thu Nov 2 22:40:49 EDT 2017


 
I am trying to catch a key press but it is not working. How can I fix this code? There is no error message so there is no error message to do a search on.
I am using Python3.5 64-bit inside the terminal.

while True:
    key = input("Enter a letter: ")
    if key == ord('q'):
         break
 
 The loop keeps running even though I have pressed the letter 'q'.



More information about the Python-list mailing list