$size = @array; $size2 = @pattern; foreach $line(@array) { if (@array[0 .. $size] =~ @pattern[0 .. $size2]) { print $line; } }
In reply to Re: comparing two arrays and displaying scalar matches
by pipeops
in thread comparing two arrays and displaying scalar matches
by pipeops
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |