Comparable Interface

The Comparable interface is used to compare two objects, and contains the method compareTo().