In Jupyter, using python 3, I am trying to run a cell that is supposed to ask for a single character input in a for loop and store the answer in a list. I wanted to avoid the use of input() to avoid having to press enter everytime.
Working in windows, I tried:
import msvcrt
charlist = []
for x in range(10):
print("Some prompt")
a = msvcrt.getch()
charlist.append(a)
but when running the cell, the kernel gets stuck at the first instance of the getch() line without accepting any input. Is there any way to do this in a Jupyter notebook?