From: Belorion Date: 2005-11-19T00:42:25+09:00 Subject: Re: IO.lineno= not behaving as expected ------=_Part_3588_11453504.1132328542191 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline > > If remember that the docn says that lineno=3D just changes the current > value of lineno -- if you check the result of f.lineno after your > f.readline above, you'll get 5. Not sure how useful that behavior is, > but that's how it's defined.... I noticed that ... but, what, exactly is that useful for? (as you already questioned) It seems like I am missing something here, because otherwise lineno=3D() seems useless and misleading. Suggest that you read the file into memory and split it by lines > (File#readlines IIRC, not near the manual now). > The only problem with that is I need to query, say, only 1000 lines in a file with 195_199_572 lines in it. ------=_Part_3588_11453504.1132328542191--