Ikegami already provided a very compact solution using a hash. A more explicit (looped) variant would read like:
... for my $element (@array2) { my ($num, $txt) = split /#/, $element; # extract parts print "$txt = $num\n" if grep $num eq $_, @array1 # use text compa +rison and print txt part } ...
Regards
mwa
In reply to Re: checking the matches
by mwah
in thread checking the matches
by tweetymonk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |