On Wed, 2005-03-02 at 11:22 +1300, [EMAIL PROTECTED] wrote: > Quoting Sean Perry <[EMAIL PROTECTED]>: > > > for line in sys.stdin.readlines(): > > # handle the line > > > > I tend to use xreadlines() which does not read the entire input at once. > > xreadlines() these days just does 'return self', I believe. File objects are > their own iterators; you can just do: > > for line in sys.stdin: > # do stuff >
Same as Max Noel said, must be a good idea ;) Thankyou Nick . _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor