Wells Fargo interview question

Why we need override hashcode and equals method etc