Why no open(f, "w").write()?

VanL news at lindbergs.org
Thu May 30 00:01:40 EDT 2002


Ok, I've read the thread... but how is

open(f, 'w').write(stuff)

different than

lines = open(f).readlines()

in terms of bad/good programming practice?

I use that second construction quite frequently.

VanL




More information about the Python-list mailing list