Question: Consider the data sheet below that tracks employee hours worked over four days: Based on the above information, write a Java program that performs the
Consider the data sheet below that tracks employee hours worked over four days:
Based on the above information, write a Java program that performs the following tasks:
Task : Recreate the matrix as a twodimensional array by reading all values from the text file
User input is not needed
Task : Calculate and print the total number of hours worked across all employees
Task : Find the employee who worked the greatest number of hours Hint: Total all of the
columns in each row. Keep track of the "largest" row and the employee associated to that row.
Task : Find the day that had the greatest number of working hours over all employees Hint:
Total of each column. Keep track of the column with the "greatest" total and the day associated
to that column.
Task : Save the information that your program has created to a text file called workingData.txt
Sample Output to be saved to workingData.txt:
The total number of hours worked across all employees:
The employee that worked the greatest number of hours was Employee working hours
The day with the greatest number of working hours was Day with hours
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
