in reply to Re: Variables in variable names
in thread [untitled node, ID 216639]

I agree, using a matrix of some sort makes the most sense in this case. Often (actually almost always), if you find yourself using variables to hold other variable names you're looking a perfectly good data structure in the face without realizing it. Variable names like 'a4' scream MATRIX. Here's another way to represent a matrix in perl:
$matrix{'a,4'} = 20; $matrix{'b,5'} = 30;
Like the nested hash solution($matrix{'a'}{2} = 5;), it lets you use non-numeric indices but uses a little less memory. You can loop through it like so:
for my $x ('a'..'g') { for my $y (1..6) { my $val = $matrix{"$x,$y"}; ... } }