Appending to a file using Python API

lavanya lavanya.msra at gmail.com
Thu Jul 8 02:55:46 EDT 2010


Hello all,

How do you append to a file using Python os::file APIs. So that it
appends to the content of the file. Not adding the content to the new
line. But just appends next to the exiting content of the file.

Example : current content of file
A B C
if we append D to it, it should be
A B C D

Not like:
A B C
D

regards,
lavanya



More information about the Python-list mailing list