If a class implements Comparable, which method must it override?

Last Updated :
Discuss
Comments

If a class implements Comparable, which method must it override?

equals(Object obj)

compareTo(Object o)

compare(Object o1, Object o2)

hashCode()

Share your thoughts in the comments