Skip to content

node3/hashtable

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

hashtable

Hashtables map a unique key to a value to give a O(1) lookup performance. This implementation assumes that keys and values in a hash are non-negative integers only.

The hashing function used calculates the index within the slice at which the key-value record is stored. Collisions are handled using a linked list (separate chaining technique). Based on the loadfactor, hash size is updated to remain within the range 0.25 and 0.75. The cost of this operation is O(n) for n number of keys in hashtable. However, this cost amortizes over time.

About

Implementation of hashtables in golang

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages