my ( @channel, @minutes, @hours, @forever); GetOptions( " channel:s" => \@channel, "minutes:s" => \@minutes, "hours:s" => \@hours, "forever:s" => \@forever); for ( my $i=0; $i<=$#channel; $i++) { print "Channel number $channel[$i] forever $forever[$i] minutes $minutes[$i] hours $hours[$i] \n"; }