0

Can somebody tell me

} @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((name == null) ? 0 : name.hashCode()); return result; } Why is prime = 31. And result = 1. Thank q

28th Apr 2019, 5:51 PM
stephen haokip
stephen haokip - avatar
2 odpowiedzi
+ 5
What exactly is name? It's not defined anywhere.
30th Apr 2019, 12:18 PM
Sonic
Sonic - avatar