1
0
Fork 0

accept EOF as valid reason to end

This commit is contained in:
Kevin Matz 2018-10-28 17:12:12 -04:00
parent b3e7c9c3ef
commit 9fc84b8241
1 changed files with 1 additions and 1 deletions

View File

@ -65,7 +65,7 @@ if __name__ == '__main__':
while True:
try:
text = input("comment# ")
except KeyboardInterrupt:
except (KeyboardInterrupt, EOFError):
text = 'exit'
print(text)
if text == 'exit':