in reply to how to print two array with new line at end of each second array element, using a single print statement?

A little addition, we can still use 'our' basic hash: like this

#!/usr/bin/perl use warnings; use strict; my @nums=(1,2,4,5,8,9); my @dats=(3,9,14,10,12,8); my %ha; @ha{@nums}=@dats; print $_,' ',$ha{$_},$/ for sort keys %ha;
  • Comment on Re: how to print two array with new line at end of each second array element, using a single print statement?
  • Download Code