Thanks for the link, now I got my answer. However, now a more serious question is raised.
According to perldata, the denominator of that fraction is the number of units of momery, perl has allocated for your hash, and more interestingly, the denominator is always a number of 2's power.
This algorithm of allocating memory really worries me, because it indicates, that it intends to waste more memory, when your hash gets bigger, because whenever you used up the memory been already allocated, perl would just double it.
I can understand the thought behind this algorithm, one is thinking, okay, I already gave you a big piece of memory, but it is still not big enough for you, instead of wasting time to give you all those small pieces, let's just double the memory I gave you.
I can understand this is a space vs. time thing, and I have no problem with that, but I still feel this algorithm is way too rough. there must be other more delicate/fine solutions.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.