"Michiel Overtoom" <[EMAIL PROTECTED]> wrote

Let me suggest some improvements. You can process all the lines in a
textfile like this:

   for line in open("dates.txt").readlines():
       print line

Or just

for line in open("dates.txt"):
   print line.rstrip()

So, your little homework program becomes more pythonic like this:

Spoilsport, you showed him the answer! :-)

Alan G

_______________________________________________
Tutor maillist  -  [email protected]
http://mail.python.org/mailman/listinfo/tutor

Reply via email to