You need to dereference the hash:
%hash = ( key1 => { subkey1 => 'value1', subkey2 => 'value2', subkey3 => 'Ovid' } ); print scalar keys %{$hash{ key1 }};
Cheers,
Ovid
Join the Perlmonks Setiathome Group or just click on the the link and check out our stats.
In reply to (Ovid) Re: scalar subkeys %hash ?
by Ovid
in thread scalar subkeys %hash ?
by crazysniffable
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |