Skip to content

Instantly share code, notes, and snippets.

@arynyklas
Last active May 11, 2023 12:47
Show Gist options
  • Save arynyklas/4ec2a659e1388e351e71c85e720bd48d to your computer and use it in GitHub Desktop.
Save arynyklas/4ec2a659e1388e351e71c85e720bd48d to your computer and use it in GitHub Desktop.
from typing import List
def long_input(prompt: str) -> str:
result: List[str] = []
print(prompt)
while True:
result_ = input()
if not result_:
break
result.append(result_)
return "\n".join(result)
# Usage:
long_input("Prompt:")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment