On Wed, 26 Jan 2011 11:32:03 -0500, mpnordland wrote:

> What is the correct file mode to pass to open() when I want to both read
> and write on the open file?

open("filename", "r+") for text mode, "r+b" for binary mode. If your 
operating system does not distinguish between the two, you can use either.

More detail is available in the Fine Manual, or in the interactive help:

help(open)

at the Python prompt.

-- 
Steven
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to