Help for this page

Select Code to Download


  1. or download this
    while (my ($test1, $test2) = (scalar <$fh1>, scalar <$fh2>)) {
       last unless defined $test1 or defined $test2;
       ...
    }
    
  2. or download this
    while ( my $test1, $test2 ) = (scalar <$fh1> // (), scalar <$fh2> // (
    +) ) {
        ...
    }
    
  3. or download this
    sub read_double_file {
        my ($fh1, $fh2)                 = @_;
    ...
    while ( my ($line_from_1, $line_from_2) = read_double_file($fh1, $fh2)
    + ) {
        ...
    }