[Tutor] This Deletes All my Files

Chad Crabtree flaxeater at yahoo.com
Fri Feb 4 07:39:43 CET 2005

I've tried this and I cannot figure out why this does not work.  I 
figure this has something to do with order of operations.  I figured 
someone would know exactly why it doesn't work.  Wouldn't this start 
inside parens then from left to right?

open(item,'w').write(open(item,'r').read().replace(' ',''))

I tried this on the shell just trying to do some quick text
because I could figure out how to get awk to do it, and I didn't want
spend 5 hours RTFM.  I got it to work by breaking it up to several 
statements, but I would like to know.

Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 

More information about the Tutor mailing list