Joel.Watson92@gmail.com | LinkedIn: /in/joel3rbear | Twitter: @Joel3rBear
HashTables are very useful for storing and retrieving data when the order is not important. This is because they determine the location of the data using a hash which will consistently calculate the same location for the same piece of data. For this reason they are not useful for searching or sorting.
A good hash function has to be consistent, always creating the same output for any given input. This is important when you want to store or retrieve anything in the table.
Reducing the number of collisions in a hashtable improves its worst case runtime since every collision results in multiple elements in a bucket.
Each index of a hashtable holds a bucket. This allows each index of the hashtable to store multiple elements in the case of a collision.