Commit f3496fa3 by BellCodeEditor

save project

parent cd5b8782
Showing with 50 additions and 0 deletions
def qui():
total = []
while True:
try:
unit = input("请输入:")
a=int(unit)
except:
if unit == "q":
break
else:
print("错误")
else:
if unit == "q":
break
total.append(a)
return total
def sum(money):
w=0
for i in money:
w=w+i
return w
\ No newline at end of file
import weq
d=weq.qui()
s=weq.sum(d)
print(s)
\ No newline at end of file
total = []
while True:
try:
unit = input("请输入:")
a=int(unit)
except:
if unit == "q":
break
else:
print("错误")
else:
if unit == "q":
break
total.append(a)
return total
def sum(money):
w=0
for i in money:
w=w+i
return w
\ 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