Question: Java: Write a program that gathers input from the user and writes the information out to a file ( output . txt ) . Your

Java:
Write a program that gathers input from the user and writes the information out to a file (output.txt).
Your main method should gather the input, calculate the average, and write the output. You should have a separate method that writes the output to a file. You can have other methods as well if you choose. However, you MUST have at least one other method in addition to the main method.
If you need help with file output, be sure to watch the recording in the readings section above.
Inputs:
Student Name
Course Number
Grades 1-5(5 individual grades)
Output:
Student Name: [student name]
Course Number: [course number]
Grade 1: [grade 1]
Grade 2: [grade 2]
Grade 3: [grade 3]
Grade 4: [grade 4]
Grade 5: [grade 5]
Average: [grade average]
Example output.txt file:
Student Name: Marty McFly
Course Number: ITC260
Grade 1: 90
Grade 2: 85
Grade 3: 70
Grade 4: 99
Grade 5: 96
Average: 88

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 Programming Questions!