Ask coding questions

← Back to all posts
How do I use the getkey package?
srsly (30)

So I tried using the getch package and the keyboard package but it would keep giving me an error. Can someone give me a getkey example?

Answered by Coder100 (16985) [earned 5 cycles]
View Answer
Comments
hotnewtop
Coder100 (16985)

yes

from getch import getch

print('press a key any key')
print('you pressed', getch())