Feb-20-2019, 08:55 AM
(This post was last modified: Feb-20-2019, 08:55 AM by Shameendra.)
nvm. I solved it by enumerating over the lines in the file. My code :
with open("Result.txt") as f: for i, line in enumerate(f): with open(f"{i+1}.txt", "w") as g: g.write(line)