Help for this page

Select Code to Download


  1. or download this
    foreach my $entry (@file1) {
       $index{$entry} = 1
    ...
    foreach my $entry (@file2) {
       $index{$entry} += 2;
    }
    
  2. or download this
    foreach my $entry (@file1) {
       $index{$entry} = 1
    ...
       # '||0' is to still the warnings under 'use warnings'
       $index{$entry} += 2 if (($index{$entry}||0) < 2);
    }