Answered step by step
Verified Expert Solution
Question
1 Approved Answer
The College class contains the following fields and methods: - list: ArrayList of Student, to store the students _ _ _ _ _ _ _
The College class contains the following fields and methods:
list: ArrayList of Student, to store the students
public void enrollStudent : adds a student to list
public boolean searchById int studentId: returns true if
studentId is found to be the id of a student in list false
otherwise
public boolean addCourse int studentId, int crn : returns
true if crn can be added to listOfCrns, the list of courses of
the student whose id number is studentId
public boolean deleteCourse int studentId int crn :
returns true if crn can be deleted from listOfCrns, the list
of courses of the student whose identification number number
is studentId.
public void printInvoice int studentId : prints the fee
invoice for the student whose identification number is
studentId.
public void printSortedInvoice int studentId : prints the
fee invoice, sorted by course number, for the student whose
identification number is studentId. Note that you should not
sort the private field listOfCrns of the Student class.
The DriverClass class contain:
private static College valenceCollege;
two methods, mainMenu, subMenu and main. The mainMenu is for
the main options, and subMenu for addingdeleting a crn
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started