python实现多行输入方法有两种
1.通过try...except实现
a = []
while True:
try:
a.append(input())
except EOFError:
print(a)
break
2.通过sys.stdin实现
import sys
for line in sys.stdin:
print(line) # line就是每行的内容
3.输入结束方式
windows环境下:ctrl+D