The Comparator interface has its own equals() method. Any class will get equals() by default through Object class. What is the need to have equal
equals()
equal
From the Java documentations, the reason why Comparator has it's own equals() method:
Comparator
However, overriding this method may, in some cases, improve performance by allowing programs to determine that two distinct comparators impose the same order.