Commit d0e52eaf by BellCodeEditor

save project

parent 3a637162
Showing with 8 additions and 7 deletions
......@@ -15,10 +15,11 @@
# print("有")
# sss.close()
with open(r'C:\Users\Administrator\Desktop\text.txt','a',encoding='utf-8')as sss:
for a in sss
if '小强:12本'in a:
a=a.str.replace('小强:12','小强:11')
for a in sss
if '小兰:12本'in a:
a=a.str.replace('小兰:12','小兰:14')
with open(r'C:\Users\Administrator\Desktop\text.txt','r',encoding='utf-8')as sss:
for a in sss:
# if '小强:12本'in a:
# a=a.str.replace('小强:12','小强:11')
# for a in sss:
# if '小兰:12本'in a:
# a=a.str.replace('小兰:12','小兰:14')
print(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