use Getopt::Std; require "/path/filename"; # Here's my datafile. getopts('f:'); #Here's the part I'd like to have create my array of arrays #if ( $opt_f ) { # chomp $opt_f ; # @combined = $opt_f; # The offending line. #} #Here's what would work, if only the names weren't variable @combined = ( @array1,@array2); foreach $entry ( @combined ) { print "return: $entry \n"; }