[CentralOH] What is a 'bucket'?

Neil Ludban nludban at columbus.rr.com
Tue Nov 25 04:32:10 CET 2014


http://en.wikipedia.org/wiki/Hash_table

EX 39 looks like this variation:

http://en.wikipedia.org/wiki/Hash_table#Separate_chaining
"""In the method known as separate chaining, each bucket is independent,
and has some sort of list of entries with the same index."""

Note that "index" here is defined as the output of the hash function,
and entries are key,value pairs.


Compare with another variation where a bucket is a key,value pair:

http://en.wikipedia.org/wiki/Hash_table#Open_addressing


On Mon, 24 Nov 2014 17:14:15 -0800
timothy spencer <smashing_good_show at hotmail.com> wrote:
> 
> 
> 
> Hello everyone. What is a 'bucket'? I think that I may be over-thinking this. I know that a dictionary is a list of 'key: value' pairs. Is a bucket simply the slot where a pair would go? I am wondering if a bucket is a slot where multiple tuples would go. Like if a dictionary is horizontal, then I am wondering if a bucket then is a vertical slot that can have lots of tuples. Lists within lists.. Then again, perhaps it is just a slot that only holds one key:value pair. I am on Zed Shaw's book in EX 39, and his description is a little odd.
> 
> Let me know, thanks,
> 
> Tim
>  		 	   		   		 	   		  


More information about the CentralOH mailing list