Jp Calderone wrote: > fileIter = iter(big_file) > for line in fileIter: > line_after = fileIter.next() > > Don't mix iterating with any other file methods, since it will confuse the > buffering scheme. >
Isn't a file an iterable already?
[GCC 3.3.3 20040412 (Red Hat Linux 3.3.3-7)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> foo = open('sample.txt')
>>> bar = iter(foo)
>>> bar is foo
True
--
http://mail.python.org/mailman/listinfo/python-list
