Napisz do pliku w P

f = open("demofile2.txt", "a")
f.write("Now the file has more content!")
f.close()