标签: python-3.x jupyter-notebook
我尝试在Jupyter笔记本中执行此操作:
import sys with open('my_file') as f_in: sys.stdin = f_in my_list = input().split() sys.stdin = sys.__stdin__ print(my_list)
但这不起作用:输入指令等待我输入一些信息