http://qs1969.pair.com?node_id=904898


in reply to How to read every 16 line of file ?

Just read them all and discard 15 out of 16. You really do not need to get any more clever than that. The way the processing actually will work, with disk buffers and all that, being smarter won't make the slightest bit of difference, and might well make it slower.