Commit accef10a by BellCodeEditor

auto save

parent a8d02629
Showing with 16 additions and 0 deletions
d=''
with open(r"d:\桌面\csss.txt",'w',encoding='utf-8')as file:
file.write('a:13本\n')
file.write('b:10本\n')
file.write('c:15本\n')
with open(r"d:\桌面\csss.txt",'r',encoding='utf-8')as file:
for i in file:
if 'a:13本' in i:
print(i)
i=i.replace('a:13本','a:14本')
print(i)
d+=i
print(d)
# with open(r"d:\桌面\csss.txt",'w',encoding='utf-8')as file:
# file.write(d)
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