in reply to RE: Array inside hashes
in thread Array inside hashes

Thanks everyone for their help! I knew I was missing something obvious. athomason mentioned \($a, @b, %c) is the same as (\$a, \@b, \%c). But is \[$a, $b, $c) the same as \$a, \$b, \$c? All the array elements are references, so I believe the first method would be cleaner.
$a = "foo"; $b = "bar"; $c = "baz"; @list = \[$a, $b, $c]; foreach(@list) { print $$_ . "\n"; }
Perl appears to set $list[0] to a reference to $a, $b, $c. Is there a less redundant way to say \$a, \$b, \$c?