/**
* @program: javademo
* @description: hash
* @author: sunyuhua
* @create: 2021-11-25 12:37
**/
public class NewHashTest {
public static void main(String[] args) {
NewHashTest NewHashTest=new NewHashTest();
System.out.println("==="+ NewHashTest.hash("sunyuhua"));
}
final int hash(Object k) {
int h = 0;
h ^= k.hashCode();
h ^= (h >>> 20) ^ (h >>> 12);
return h ^ (h >>> 7) ^ (h >>> 4);
}
}