On Wed, Jun 22, 2011 at 11:23 PM, Andrej Mitrovic <span dir="ltr"><<a href="mailto:andrej.mitrovich@gmail.com">andrej.mitrovich@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

What am I doing wrong here?<br>
<br>
f1 = open('Drum.d', 'r')<br>
lines = f1.readlines()<br>
f1.close()<br>
<br>
f2 = open('Drum.w', 'w')<br>
for line in lines:<br>
   #~ print(patt.sub(replacer, line))    # This replaces the parens correctly<br>
   f2.write(patt.sub(replacer, line))     # But the file ends up being<br>
the same..<br>
f2.close()<br>
</blockquote></div><br><div><br></div><div>That looks 100% right.</div>