Commit dc44675d by BellCodeEditor

save project

parent 44261134
Showing with 7 additions and 1 deletions
...@@ -3,5 +3,10 @@ with open(r'C:\Users\Administrator\Documents\lesson13-1\sales_list.txt','r',enco ...@@ -3,5 +3,10 @@ with open(r'C:\Users\Administrator\Documents\lesson13-1\sales_list.txt','r',enco
#print(a) #print(a)
for i in a: for i in a:
b=i.split() b=i.split()
print(b[1:]) # print(b[1:])
c_111=0
for i in b[1:]:
c_111=c_111+int(i)
result=b[0]+str(c_111)
print(result)
\ 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