Question: 9B: Implementing the Comparable Interface Submit the archived project to BB Our job is to compare two Students that are characterized by a String name

 9B: Implementing the Comparable Interface Submit the archived project to BB

9B: Implementing the Comparable Interface Submit the archived project to BB Our job is to compare two Students that are characterized by a String name and a long campusID. Specifically, 1. Create a Student class which implements the Comparable interface and contains the following fields: String name campusID ong Implement the compareTo method to compare the campus D 2. Create an OuterMain class to test the compareTo method. For example, create two students like -new Studentl Carl Mustermann,4711) -new Studentl Bert Filli", 518OL Then print out the one with the older (smaller) campusID first by employing the compareTo method

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!