On Fri, May 14, 2010 at 9:25 PM, Abhishek Mishra <ideam...@gmail.com> wrote: > >>>> linear1 = ''.join(foo.split('\n')) >>>> linear2 = foo.replace('\n','') > ^^ these are the two ways in which you can linearize the input text by > removing all '\n'
+1 for the replace. More obvious, cleaner, more efficient. Hugo _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor