Commit 2946f7b9 by BellCodeEditor

save project

parent 4a12c8b3
Showing with 7 additions and 3 deletions
......@@ -2,5 +2,9 @@ with open(r"c:\Users\hp\Documents\lesson13-1\sales_list.txt","r", encoding="utf-
data=a.readlines()
#print(data)
for i in data:
v=i.split()
print(v[1:])
\ No newline at end of file
b=i.split()
sum=0
for j in b[1:]:
sum=sum+int(j)
d=b[0]+str(sum)
print(d)
\ 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