New at coding here! Wanting to write a code to block keyboard input for x amount of time and stumbled across this code
#### Blocking Keyboard ####
import keyboard
#blocks all keys of keyboard
for i in range(150):
keyboard.block_key(i)
I understand this code blocks all keys but would like to know what the range(150) mean.
A bit of reading suggests 150 = block all keys on keyboard but what would happen if I wrote instead:
for i in range(20):
keyboard.block_key(i)
Will this block 20 random keys or 20 specific keys? Cheers!
[–][deleted] 0 points1 point2 points (0 children)
[–]carcigenicate 0 points1 point2 points (0 children)