Java System identityHashCode() MethodThe identityHashCode() method of Java System class returns hash code for the specified object. It is returned by the default method hashCode(). SyntaxParameterx - object for which the hashCode is to be calculated Returns
Example 1Test it NowOutput: identity hash code of object a = 743673026 identity hash code of object b = 743673026 identity hash code of object c = 557722442 Example 2Test it NowOutput: identity hash code of object a = 843730481 identity hash code of object b = 743673026
Next TopicJava System
|