$30
Project3
CECS277
Submit project3.java file before the deadline
Please make sure to follow the naming convention for project.
You don’t need to send scores.txt file.
Make sure to use file exception handling using:
import java.io.FileNotFoundException;
Description:
Write a program that will read the information of students from scores.txt file. Your
program should calculate student’s average test scores and their letter grades. Use
ArrayLists for this project. One ArrayList to store the student’s names. The other
ArrayList would store the test scores, and an ArrayList to store the letter grades. Your
program should contain the following functions.
• readData() Method to reads and stores the data into two ArrayLists.
• calculateAverage() Method to calculate the average test scores and grades.
static double calculateAverage(ArrayList<Double> scores)
• findLowestScore() Finds the lowest score and returns it to the calculateAverage().
static double findLowestScore(ArrayList<Double> scores)
• writeData() Method to write the result into a file result.txt. This Method should
write student name, average, and letter grade into the file.
• classAverage() This method will find the class average and returns it. Class Average
will be stored as the last line in the result.txt file.
• Use the following Criteria for letter grades.
If Average is 98-100… Assign the grade “A+”
If Average is 95-97… Assign the grade “A”
If Average is 91-94… Assign the grade “A-”
If Average is 88-90… Assign the grade “B+”
If Average is 84-87… Assign the grade “B”
If Average is 80-83… Assign the grade “B-”
If Average is 75-79… Assign the grade “C+”
If Average is 70-74… Assign the grade “C”
If Average is less than 70 and greater than 60 assign grade “D”
If Average is less than or equal 60 assign grade "NC"