Commit c782c512 by BellCodeEditor

save project

parent d40c6c7d
Showing with 7 additions and 5 deletions
with open(r"C:\Users\Admin\Documents\lesson13-1\sales_list.txt",'r',encoding='utf-8')as file: with open(r"C:\Users\Admin\Documents\lesson13-3\sales_list.txt",'r',encoding='utf-8')as file:
a=file.readlines() a=file.readlines()
for i in a: for i in a:
e=i.spile() e=i.split()
print(e[0]) sum=0
print(e[1:]) for s in e[1:]:
\ No newline at end of file sum=sum+int(s)
print(sum)
\ 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