That is assuming that blank lines may or may not include spaces. If you know that they will not, you could save yourself a good deal of time (especially for large files) by simply testing $_ ne "" in the grep.@data = grep { $_ !~ /^\s*$/ } @a; my $length = scalar @data;
In reply to Re: File length ??
by charnos
in thread File length ??
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |