<div style="font-family: arial, helvetica, sans-serif; font-size: 10pt"><div dir="ltr">On Tue, Dec 4, 2012 at 12:09 AM, Sean Silva <span dir="ltr"><<a href="mailto:silvas@purdue.edu" target="_blank" class="cremed">silvas@purdue.edu</a>></span> wrote:<br>
<div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Not that it's a big deal, but the "official" coding convention for<br>

Python <<a href="http://www.python.org/dev/peps/pep-0008/" target="_blank" class="cremed">http://www.python.org/dev/peps/pep-0008/</a>> uses 4-spaces. With<br>
significant whitespace I find that something a bit stronger than 2<br>
spaces is needed for keeping track of the start/end of blocks.<br></blockquote><div style><br></div><div style>Meh, my editor does 2 space indent, so that's what i've used.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Also you should be able to simplify the for-loop to<br>
<br>
    for i, l in enumerate(f):<br>
<br>
since iterating over a file automatically iterates over its lines.<br></blockquote><div><br></div><div style>Yea, I wanted the clarity of readlines -> temporary array -> writelines.</div><div><br></div></div></div>
</div></div>