Question: This program studies use of the ArrayList class and the String split method. It practices with file input using a BufferedReader and use of try/catch

This program studies use of the ArrayList class and the String split method. It practices with file input using a BufferedReader and use of try/catch blocks. 1. Design class Student. Provide data members for string student identification number ("100001"), student name ("Mary Smith"), student major ("CIS"), and number of credit hours (55). Provide default and parameterized constructor, accessors, mutators, and toString methods. Include a boolean canGraduate method which returns true if the student has at least 60 credit hours, else false. 2. Input file graduate.txt contains data about students who have filed for graduation. This data should be read into an ArrayList of Student using a BufferedReader object. Read the line and practice using the String split method to split into tokens on the comma. Use the pieces to create the Student object. A try/catch block is used for file IO errors. Report the error and end the code. 3. Input file summer.txt contains a list of student identification numbers and number of credits earned at summer school. Find the student by the student identification number and add summer credits to current credits. For example, identification 100400 belongs to Michael Charles. After adding the 2 summer credit hours to the original 59, this student now has 61 credit hours. A try/catch block is used for file IO errors. Report the error and end the code. 4. Produce a report of student names who will graduate from each major ("BUS", "CIS", "MAT") followed by a report of students who will not graduate (see sample output). 5. The following static methods in the main application are required. Other methods may be added as desired.

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!