what is the meaning of comparator class
Comparators classes
Comparator interface is used to order the objects of user-defined classes. A comparator object is capable of comparing two objects of two different classes. it is used to make comparisons as per the need of the programmer