Commit 6c258087 by BellCodeEditor

save project

parent 5d4fa219
Showing with 4 additions and 2 deletions
...@@ -4,9 +4,10 @@ def new_input(): ...@@ -4,9 +4,10 @@ def new_input():
try: try:
unit= int(input("请输入:")) unit= int(input("请输入:"))
except: except:
if unit== 'q': print('请输入数字!')
break
else: else:
if unit==9:
break
total.append(unit) total.append(unit)
print(total) print(total)
new_input() new_input()
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment