in reply to Concordance Printing of Two Arrays
Hi Eddie,
Use List::MoreUtils Module to do this.
use List::MoreUtils qw(pairwise); use Data::Dumper; my @num = qw (1 2 3 4 5); my @alp = qw (A B C D E); @result=pairwise{($a.'-'.$b)}@num, @alp; print Dumper(\@result);
Output:
$VAR1 = [ '1-A', '2-B', '3-C', '4-D', '5-E' ];
Thanks
Gopal.R
In Section
Seekers of Perl Wisdom