This article explains the relationship between hashcode and equals method in Java. In Java, hashcode method and equals methods are interdependent and while we implement equals method we should implement hashcode method also which is contract between hash code and equals method. Let us have an insight of hashcode and equals method.