Is this the cleanest way to write a list to a file, since writelines() doesn\'t insert newline characters?
writelines()
file.writelines([\"%s\\n\" % item fo
In Python3 You Can use this loop
with open('your_file.txt', 'w') as f: for item in list: f.print("", item)