in reply to Count number of lines in a text file
open (FILE, $ARGV[0]) or die "Can't open '$ARGV[0]': $!"; $lines++ while (<FILE>); close FILE; print "$lines\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Count number of lines in a text file
by davidrw (Prior) on Mar 23, 2006 at 20:45 UTC |