Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- a = 0
- b = "|"
- while a < 100000:
- a += 1 # Same as a = a + 1
- new = (a,b)
- f = open("export.txt","a") #opens file with name of "export.txt"
- f.write(str(new))
- f.close()
- infile = "export.txt"
- outfile = "newfile.txt"
- delete_list = ["(","," "'"]
- fin = open(infile)
- fout = open(outfile, "w+")
- for line in fin:
- for word in delete_list:
- line = line.replace(word, "")
- fout.write(line)
- fin.close()
- fout.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement