delete first line in a file

Juergen Huber juergen.huber at kirchnersoft.com
Fri Jun 30 06:47:44 EDT 2006


Fredrik Lundh wrote:
> Juergen Huber wrote:
>
>> i am a dummy user in python and new in this programming language and
>> so there will be questions, that´s for you no problem! i never have
>> before programmed in any language! sorry for this! i hope you will
>> help me, that i also could the basics in this language! and later
>> many more, so i hope ! :)
>>
>> the first question for me in this newsgroup will be the follow one:
>>
>> - is there a way to delete in a csv-file the first line?!
>
> in general, modern file systems can only remove and add stuff at the
> end of a
> file, so the only way to do this is to rewrite the entire file.
>
> (you can either load the entire file, fix it up, and write it out
> again, or copy the file to a new file, skipping the first line or
> row).
>
> </F>

ok...i thought as much, that i have to copy this file!

how will i do that?!
how will i fix this file => delete the first line?!

with which commands could i do that?!

thanks




More information about the Python-list mailing list