0
点赞
收藏
分享

微信扫一扫

ACM中获取多行输入 Python

幺幺零 2022-03-26 阅读 39

获取每一行输入

while True:
	theInput = input()

存储多行输入

inputs = []
while True:
	theInput = input()
	inputs.append(theInput)

加入终止判断

inputs = []
while True:
	theInput = input()
	try:
        inputs.append(theInput)
    except EOFError:
        break

相关文章

  1. ACM的Python版输入输出
  2. (Python3输入输出)ACM的python输入输出格式
  3. python在ACM中的输入应用
  4. Python3的多行输入
举报

相关推荐

0 条评论