Write a compareTo method for the Puma class that uses two in…
Write a compareTo method for the Puma class that uses two instance variables to determine order: name (String) and maxSpeed (int). The ordering of Puma established by this class is: Order first by maxSpeed, in ascending order. Order second by name, in ascending lexicographical order (String’s compareTo). If both variables are the same between the instances, the pumas are equal. You do not have to add the code for the instance variables.