• + 0 comments
    // Write your Checker class here
    class Checker implements Comparator<Player> {
        public int compare(Player a, Player b) {
            if (a.score != b.score) {
               return b.score - a.score; 
            }
            else {
                return a.name.compareTo(b.name);
            }
        }
    }