Commit db468e58 by BellCodeEditor

save project

parent 17948955
import func
a=func.totol
c=b(a)
a=func.totol()
c=func.b()
print("您总共消费",c,"元")
\ No newline at end of file
......@@ -13,11 +13,11 @@ def totol():
total.append(unit)
#print(total)
return total
def b(c):
def b(s):
sum=0
for i in c:
for i in s:
sum=sum+i
return sum
#a=totol()
#c=b(a)
#print("总和是",c)
\ No newline at end of file
a=totol()
c=b(a)
print("总和是",c)
\ 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