Commit e61d7229 by BellCodeEditor

auto save

parent 6d261686
Showing with 8 additions and 15 deletions
li=['小','虎','语'] f=open(r'c:\Users\29018\Documents\lesson13-1\sales_list.txt','r',encoding='utf-8')
file=open('C:\\Users\\29018\\Desktop\\test.txt','w',encoding='utf-8') a=f.readlines()
file.writelines(li) print(a)
\ No newline at end of file f.close()
\ No newline at end of file
ww=open(r'c:\Users\29018\Documents\lesson13-1\sales_list.txt','w····',encoding='utf-8')
ww.write('悟空 122 34 67\n积极 23 90 89')
ww.close()
ww=open(r'c:\Users\29018\Documents\lesson13-1\sales_list.txt','r',encoding='utf-8')
b=ww.readlines()
print(b)
for i in b:
print(i)
悟空 122 34 67 open(r'c:\Users\29018\Documents\lesson13-1\sales_list.txt','r',encoding=utf-8)
积极 23 90 89 \ No newline at end of file
\ 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