Logo 
Search:

Java Answers

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds
  Question Asked By: Rani Singh   on Nov 06 In Java Category.

  
Question Answered By: Sebastien Anderson   on Nov 06

I think you haven't properly worked with the objects. When you create a
instance of a class  and print  it it gives the address of the object, and if you
want to see the hash code then you have to use the object.hashCode() method..
you can try this out

create an object of a class simply print it and print the object.hashCode()
value both will be different...

Share: