Commit e4ca2e4f by BellCodeEditor

save project

parent b8409456
Showing with 1 additions and 0 deletions
...@@ -16,6 +16,7 @@ with open(r'C:\Users\Administrator\Desktop\w.txt','r',encoding='utf-8') as file: ...@@ -16,6 +16,7 @@ with open(r'C:\Users\Administrator\Desktop\w.txt','r',encoding='utf-8') as file:
data=data.replace('小强:10本','小强:11本') data=data.replace('小强:10本','小强:11本')
if '小兰:12本' in data: if '小兰:12本' in data:
data=data.replace('小兰:12本','小兰:14本') data=data.replace('小兰:12本','小兰:14本')
new_data+=data
with open(r'C:\Users\Administrator\Desktop\w.txt','w',encoding='utf-8') as file: with open(r'C:\Users\Administrator\Desktop\w.txt','w',encoding='utf-8') as file:
file.write(new_data) file.write(new_data)
with open(r'C:\Users\Administrator\Desktop\w.txt','r',encoding='utf-8') as file: with open(r'C:\Users\Administrator\Desktop\w.txt','r',encoding='utf-8') as 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