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 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
Get step-by-step solutions from verified subject matter experts
