<div class="gmail_quote">On Wed, Jul 14, 2010 at 12:26 PM, Alan Gauld <span dir="ltr">&lt;<a href="mailto:alan.gauld@btinternet.com">alan.gauld@btinternet.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

<br>
If you never need a stripped version of line again, or if you<br>
are planning on writing it out to another file then this is fine.<br>
If you are going to use it again its probably better to strip()<br>
and asign to itelf:<br>
<br>
line = line.strip()<br>
<br>
Also you might find rstrip() slightly safer if you have any<br>
unusual characters at the start of line...<br></blockquote><div></div><br>Thanks for the tip Alan, I think I&#39;ll assign it to itself. <br></div>