From the doc of Java about Hashtable class, it says
As a general rule, the default load factor (.75) offers a good tradeoff between time and space costs
So the load factor for Hashtable is 0.75, which means if there are N keys, Hashtable will use M = N/0.75 spaces to store them.
In CLRS book, it also introduces load factor alpha.
But from my understanding, CLRS intends to set alpha larger than 1, i.e., M = N/alpha < N. This means a Hashtable can use M slots where M < N so that it can save storage from unused keys.
I say M < N can save storage because normally we don't know exactly value for N, but we know the set of the keys and use N to stand for possible number of keys. The set of the keys may be very big, but the number of actual keys in use is very small. So setting M smaller than N can save the storage. Also this is why normally Hashtable does not use a direct array to map every {key, value} 1:1.
But Hashtable in Java use storage more than N. I think it is not consistent with the CLRS design, right?
Am I right?
thanks