in reply to Re: Re: Re: Re: print scalar %hash... erm
in thread print scalar %hash... erm
As an lvalue `keys' allows you to increase the
number of hash buckets allocated for the given
hash. This can gain you a measure of efficiency
if you know the hash is going to get big. (This
is similar to pre-extending an array by assigning
a larger number to $#array.) If you say
keys %hash = 200;
then `%hash' will have at least 200 buckets
allocated for it--256 of them, in fact, since it
rounds up to the next power of two. [...]
|
|---|