Commit 9f47df4b by BellCodeEditor

save project

parent a8d02629
Showing with 18 additions and 0 deletions
file=open(r"C:\Users\双师001\Desktop\捐赠.txt","w",encoding='utf-8')
file.write("陈熙瑷:28\n")
file.write("邢钟月:47 \n")
file.close()
file=open(r"C:\Users\双师001\Desktop\捐赠.txt","r",encoding='utf-8')
a=file.readlines()
new_data=""
for data in a:
if "陈熙瑷:28" in data:
data=data.replace("陈熙瑷:28","陈熙瑷:29")
print("数据在")
new_data=new_data+data
print(new_data)
file=open(r"C:\Users\双师001\Desktop\捐赠.txt","w",encoding='utf-8')
file.write(new_data)
\ 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