Commit b75bf20d by BellCodeEditor

save project

parent afdb1735
Showing with 8 additions and 3 deletions
......@@ -12,6 +12,11 @@ def test():
else:
total.append(unit)
return total
def cal(money):
total=0
for i in money:
total+=i
return total
list=test()
print(list)
\ No newline at end of file
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