I have implemented my own hash table functions in C, but currently it doesn’t support resizing. I was wondering what algorithms do exist apart from the brute-force way of creating a new empty hash table and moving everything there?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There is incremental resizing.
From Wikipedia:
So this is not some clever way of moving all of the elements from the old table into the new table (and if there is one, I haven’t seen it); rather, it eases the burden of resizing by allowing the migration to happen gradually.