Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

This part is a practice of: Reading from a text file . . Defining a class Creating objects Using Java's Linkedlist For this part, you

image text in transcribed
This part is a practice of: Reading from a text file . . Defining a class Creating objects Using Java's Linkedlist For this part, you are required to write a program named w/_part3 jaw, which reads grades of grading components from a text file. For this assignment, you need to store students grade mformation i Linked ist. Follow the mstructions given below. An imput file, named student_grades of, contains grades of grading components of a number of students. The format of the input file 15: John, 90, 100, 70, 96 Susan, 85, 90, 100, 100 Molly, 93, 90, 95, 92 Lindsey, 80, 100, 92, 100 Jake, 75, 80, 82, 70 Gabe, 95, 100, 100, 88 Each lime has grades of one student. Note that tokens are separated by "a comma and a space." You need this information when you parse the line (or separate the tokens). The first token is the name of a student and the four numbers that follow are homework grade, project grade, midterm grade, and the final exam grade, in that order. following: You must define a class named CourseGrade in a separate CourseGrade jova file. The class definition must include at least the A constructor, which receives homework grade, project grade, midterm grade, and the final exam grade as arguments. The following instance variables private String name} private int homework; private int project; private int midterm; private int finalExam;| All necessary getter and setter methods. Then, your program must (within the main method of Hwl_part3 java): . . Read the input file, one line at a time Parse a line (or separate tokens Create an object of CourseGrade class Add the object to a Linkedlist Repeat the above until all lines in the imput file are read Print all students' grades in the following format: Number of students is: 6 Name = John, Average = 88.1, Letter grade = B+ Name = Susan, Average = 94.5, Letter grade = A Name = Molly, Average = 92.85, Letter grade = A- Name = Lindsey, Average = 92.0, Letter grade = A- Name = Jake, Average = 75.5, Letter grade = C Name = Gabe, Average = 94.3, Letter grade = A Note that your program must determine the average and the letter grade of each student. Documentation No separate documentation is needed. However, you must include sufficient inline comments within your program

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Programming questions

Question

What is business continuity planning? Why is it needed?

Answered: 1 week ago