for (@fuente) { my @parts = split /\|/; ++$seen{$parts[1]} = $_; } for (@fuente2) { my @parts = split /\|/; if ($seen{$parts[2]}) { print $seen{$parts[1]}; # That's the matching line from @fuente print; # That prints the line from @fuente2 } }
In reply to Re: How compare two files
by Roy Johnson
in thread How compare two files
by Daredevil--
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |