మీరు equals() అను logical equality నిర్వచించడానికి override చేసినప్పుడు, మీరు hashCode() కూడా override చేయాలి — ఎందుకంటే hash-based collections (HashMap, HashSet) contract పై ఆధారపడి ఉంటాయి, అంటే . ఇది breaking చేస్తే subtle, hard-to-find bugs ఏర్పడతాయి.
