Commit 12a21b60 by BellCodeEditor

save project

parent 4a1b39ff
Showing with 8 additions and 5 deletions
def new_input():
total = []
while True:
try:
unit=int(input("请输入:"))
unit=input("请输入:")
if unit== 'q':
break
except:
print("请输入整数")
else:
total.append(unit)
try:
unit=int(unit)
except:
print("请重新输入一个数子")
else:
total.append(unit)
print("_"*30)
print(total)
new_input()
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