Commit 9f63ce2a by BellCodeEditor

save project

parent c4ceba4f
Showing with 8 additions and 3 deletions
...@@ -13,8 +13,13 @@ file.close() ...@@ -13,8 +13,13 @@ file.close()
with open(r"C:\Users\Administrator\Documents\test.txt",'r',encoding='utf-8') as file: with open(r"C:\Users\Administrator\Documents\test.txt",'r',encoding='utf-8') as file:
for data in file: for data in file:
if "常山赵子龙:200000000本" in data: if "常山赵子龙:200000000本" in data:
print("yes") data=data.replace("精神小伙,1000","常山赵子龙,1000")
else: new_data += data
print("no") filei.write(new_data)
#else:
# print("no")
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