Update:use strict; my $counter=0; print"TOP\n"; while( $counter++<10) { last if eof(STDIN); $_=<>; print "$counter $_"; } print "BOTTOM";
In reply to Re: peeling the top 10 lines from a file
by holli
in thread peeling the top 10 lines from a file
by jjohhn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |