Commit 60b20f9d by BellCodeEditor

save project

parent cc9b8f52
Showing with 7 additions and 7 deletions
total = []
def myinput():
total = []
zongjia = 0
while True:
b = 0
nit = input("请输入:")
try:
b = int(nit)
zongjia = zongjia + b
except:
if(nit == 'q'):
return
return total
else:
total.append(nit)
total.append(b)
myinput()
print(total)
\ No newline at end of file
tt = myinput()
print(tt)
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