Commit 47fc501b by BellCodeEditor

save project

parent 326d2604
Showing with 3 additions and 2 deletions
......@@ -20,14 +20,15 @@ def ert(price):
sum=0
for i in price:
sum+=i
return sum
print("==========================================")
print(price)
print('我下面开始计算菜单的总价')
sum=ert(price)
print('菜单的总价格为:'+str(ert))
su=ert(price)
print('菜单的总价格为:'+str(su))
# '''
# 思路:
# 遍历得到列表中的每个值,然后让他们相加
......
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