title: Action upon a key press (Python)
body: <p>I want to code the following in Python. When I press a key let's say the key "a", the program needs to write to a logfile that the subject for example answered "left". </p>
  
  <p>Can you help me with this?</p>
  
  <p>Thnx a lot!</p>