When using array + singly linked list, insert head, add capacity list is also a head (concurrent infinite loop),
If add capacity for tail plug whether can solve the problem of 1.7 Hashmap infinite loop?
Question 2:
In addition, if you use an array + arrays, hashes conflict also exist in the array, the array can use dichotomy, ideal condition complexity to O (logN), but didn't use this, should be an array of larger capacity complexity?
CodePudding user response:
Question 1: you're right, 1.8 to plug the end of theQuestion 2: can't use arrays +, so get a key value is very slow