Commit 19299e1b by BellCodeEditor

save project

parent 1cb5e6bf
Showing with 7 additions and 5 deletions
......@@ -7,10 +7,12 @@
#a=file1.read()
#print(a)
#file1.close()
#a=''
#with open(r'C:\\Users\\Administrator\\Desktop\\test.txt','r',encoding='utf-8')as file:
#a=file.read()
#print(a)
#for data in file:
# if'小强:10本'in data:
# data=data.replace('小强:10本','小强:11本')
#a+=data
# print(a)
with open(r'C:\\Users\\Administrator\\Desktop\\test.txt','r',encoding='utf-8')as file:
for date in file:
if'小强:10本'in date:
print("数据在这个里面")
filel.write(a)
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