in reply to Re^2: Print contents of text file line by line
in thread Print contents of text file line by line
Unless you really want to print only selected lines of the file, you probably should use the line-by-line approach that you currently (unintentionally) wrote, and add a counter of the number of times this loop has executed, and end the loop after you have printed enough. This will work for any file regardless of size.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: Print contents of text file line by line
by TonyNY (Beadle) on Jun 25, 2018 at 13:54 UTC | |
by hippo (Bishop) on Jun 25, 2018 at 14:37 UTC |
In Section
Seekers of Perl Wisdom