Commit 4347fd2a by BellCodeEditor

save project

parent 9beea8b3
Showing with 13 additions and 9 deletions
...@@ -5,11 +5,15 @@ def new_input(): ...@@ -5,11 +5,15 @@ def new_input():
if unit== 'q': if unit== 'q':
break break
else: else:
total.append(unit) try:
except: unit=int(unit)
print("请重新输入一个数字") except:
else: print("请重新输入一个数字")
total.append(unit) else:
total.append(unit)
print(total) finally:
new_input() print("-"*30)
\ No newline at end of file return total
print(return)
\ 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