Morgan Stanley interview question

Talk about hashcode() and equals()

Interview Answer

Anonymous

2 Jun 2018

HashCode and equals to function is implemented in HashMap,Even we can override HashCode and equals function Hashcode returns index calculated with the generated HashMap and equals come into action if same index is returned by hashcode