SPUG: In over my head with hashes of arrays of arrays
Adam Monsen
haircut at gmail.com
Fri Jul 22 16:45:01 PDT 2005
Good advice by all. Also, check out Data::Dumper, an invaluable tool
at examining data structures of any kind.
use Data::Dumper;
$myhash{evens} = [ [0,2,4], [4,6,8] ];
print Dumper(\%myhash); # notice the backslash!
prints out:
$VAR1 = {
'evens' => [
[
0,
2,
4
],
[
4,
6,
8
]
]
};
There's also a cool replacement to Data::Dumper that prints out the
actual variable name instead of just $VAR1, but I forget what the name
of that module is. I suppose you can also use Data::Dumper->Dump(),
but this module that I can't remember the name of does everything for
you.
--
Adam Monsen
http://adammonsen.com/
More information about the spug-list
mailing list