Commit cc90ebad by BellCodeEditor

save project

parent c4b79040
Showing with 11 additions and 5 deletions
......@@ -4,9 +4,15 @@
# fll.write('小丽:11本\n')
# fll.write('李文:9本\n')
# fll.close()
new_data=''
with open(r"C:\Users\EDZ\Desktop\aips.txt","r",encoding="utf-8")as fll:
data=fll.read()
if '莫测:9001本'in :
print('该数据在里面')
else:
print("该数据不在里面")
\ No newline at end of file
if '小兰'in data:
data=data.replace('小兰','欧式')
new_data+=data
with open(r"C:\Users\EDZ\Desktop\aips.txt","w",encoding="utf-8")as fll:
fll.write(new_data)
# if '莫测:9001本'in :
# print('该数据在里面')
# else:
# print("该数据不在里面")
\ 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