you must override them in order to deal with collections to check the objects are equal or not and hashcode too. Because some collections are storing datas according to the hash code value(Hashing algorithms). for eg. hashtable,HashMap,HashSet.
i hope this clears you.
Joined: Oct 13, 2008
ok i got it...
the String class and the wrapper classes have overridden the equals() method (inherited from class Object), so that you could compare two different objects (of the same type) to see if their contents are meaningfully equivalent.