Commit ca636793 by BellCodeEditor

save project

parent adef0cd1
Showing with 10 additions and 4 deletions
...@@ -10,7 +10,13 @@ def test(): ...@@ -10,7 +10,13 @@ def test():
print("请输入整数") print("请输入整数")
else: else:
total.append(unit) total.append(unit)
print(total)
return total return total
list=test() def cal(money):
print(list) total = 0
\ No newline at end of file for i in money:
total+=i
return total
list=test()
print(list)
totalMoney=cal(list)
print("总价是"+str(totalMoney))
\ 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