in reply to reading 100 line at a one time
i have a file of 10000 line and i want to read each time 100 line instead of line by line as it will reduce my disk I/O.
Why would it reduce your disk IO? You'll have to read the same amount of information to read a hundred lines regardless of whether you do it in a hundred pieces or one piece and disks care absolutely nothing for line lengths.
If your hard drive or operating system have disk caches, make sure to enable them. That's the right place to optimize this for almost every application.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
reading 100 line at a one time
by contact_chatan (Initiate) on Mar 01, 2005 at 07:56 UTC | |
by chromatic (Archbishop) on Mar 01, 2005 at 08:05 UTC | |
by jZed (Prior) on Mar 01, 2005 at 08:04 UTC |