Commit efc34fc5 by BellCodeEditor

save project

parent 2124b74a
Showing with 21 additions and 2 deletions
def new_input():
total = []
while True:
money = input("请输入(q退出):")
......@@ -14,5 +15,23 @@ def new_input():
finally:
print("-"*30)
return total
result = new_input()
print(result)
def sum(money):
count =0
for i in money:
count =count+i
return count
price = new_input()
pay = sum(print)
print("您一共消费了"+str(pay))
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