Help for this page

Select Code to Download


  1. or download this
    use strict;
    use Tie::File;
    ...
    
    tie my @f => 'Tie::File' => $f;
    print "$l: $f[$l]";
    
  2. or download this
    perl -w gfarhat.pl testfile.txt 1
    perl -w gfarhat.pl testfile.txt 2
    ...
    perl -w gfarhat.pl testfile.txt 9998
    
  3. or download this
    perl -nle 'BEGIN{$l=pop}print if $.==$l' testfile.txt 1