hashcode的大揭秘


1.hashcode主要跟equal有关,当equal函数不改变,hashcode也就不发生改变

2.等价类的hashcode一定相同,而不等价类的hashcode可以相同也可以不同,相同的话查找起来会麻烦一些


Author: John Doe
Reprint policy: All articles in this blog are used except for special statements CC BY 4.0 reprint policy. If reproduced, please indicate source John Doe !
  TOC