On 4 Apr, 02:21, dean <de...@yahoo.com> wrote: > Hello, > > As the subject says how would I go about adding the lines to the beginning > of a text file? Thanks in advance.
I'd create a new file, then write your new lines, then iterate the existing file and write those lines... If no errors occcur, issue a delete for the old file, and a rename for new file to the old name. hth Jon. -- http://mail.python.org/mailman/listinfo/python-list