On Tuesday 08 March 2005 15:55, Simon Brunning wrote:
> Ah, but that's the clever bit; it *doesn't* store the whole list -
> only the selected lines.

But that means that it'll only read several lines from the file, never do a 
shuffle of the whole file content... When you'd want to shuffle the file 
content, you'd have to set lines=1 and throw away repeating lines in 
subsequent runs, or you'd have to set lines higher, and deal with the 
resulting lines too in some way (throw away repeating ones... :-). Doesn't 
matter how, you'd have to store which lines you've already read 
(selected_lines). And in any case you'd need a line cache of 10^9 entries for 
this amount of data...

That's just what I wanted to say...

-- 
--- Heiko.

Attachment: pgpTTdk42z5Yz.pgp
Description: PGP signature

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to