📜  多行输入python代码示例

📅  最后修改于: 2022-03-11 14:46:09.321000             🧑  作者: Mango

代码示例4
lines = []
while True:
    line = input()
    if line:
        lines.append(line)
    else:
        break
text = '\n'.join(lines)