Commit 56be2e07 by BellCodeEditor

save project

parent 45b1b10c
Showing with 1 additions and 2 deletions
......@@ -2,9 +2,8 @@ with open(r'c:\Users\Administrator\Documents\lesson13-1\sales_list.txt','r',enco
a=ss.readlines()
for i in a:
aaa=i.split()
print(aaa[1:])
sum=0
for sales in aaa[1:]
for sales in aaa[1:]:
sum=sum+int(sales)
rl=aaa[0]+str(sum)
print(rl)
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