Commit bed20126 by BellCodeEditor

save project

parent 9b7026e6
Showing with 12 additions and 8 deletions
total=[]
def d():
while True:
tunit=int(inpu("请输入:"))
if unit== 'q':
tunit=input("请输入:")
if tunit == 'q':
break
else:
try:
try:
tunit=int(tunit)
except:
print("请输入整数")
else:
print("已经加入")
print(total)
except:
print("请输入整数")
else:
total.append(tunit)
print("已经加入")
print(total)
return total
d()
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