python操作txt

xiaoxiao2021-02-28  84

file=open("C:\\Users\\MLP\\Desktop\\123.txt") s="" while 1: line=file.readline() if not line: break line=line[:len(line)-2]+line[len(line)-1:] line = 'http://' + line s=s+line f=open("C:\\Users\\MLP\\Desktop\\444.txt","w") f.write(s) f.close
转载请注明原文地址: https://www.6miu.com/read-76926.html

最新回复(0)