Help for this page

Select Code to Download


  1. or download this
    my $lastline = do {
        open my $pipe, '-|', tail => -1, $file
    ...
        <$pipe>;
    };
    print $lastline;
    
  2. or download this
    while( 1 ) {
        my $file = shift || last;
        # ...
    }
    
  3. or download this
    while( @ARGV ) {
        my $file = shift;
        # ...
    }
    
  4. or download this
    for my $file ( @ARGV ) {
        # ...
    }
    
  5. or download this
    for my $file ( @ARGV ) {
        my $lastline = do {
    ...
        };
        print $lastline;
    }