Program Two You have been asked to write a payroll program for a small company. They...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
Program Two You have been asked to write a payroll program for a small company. They have two files. One contains the employee information. The other contains one week's worth of work hours for the employees. Program operation The program should first open and read all of the employees from the file that lists the employees. The file consists of a single line record for each employee, with each field separated by a comma. This file has the following format: employee id, first name, last name, employee type, salary Sample entries in the file might look like the following. 101-M, Frank, Zappa, H, 22.50 103-J, Mary, McCarthy, E, 32.50 003-K, William, Ramos, C, 32.50 The possibilities for the employee type are H - hourly E - exempt C - contractor The salaries for the employees are per hour. There will also be a second file that holds the hours worked for each employee. This file looks like the following: 11/10/2020, 101-M, 8.0 11/11/2020, 101-M, 8.0 11/10/2020, 103-J, 8.5 11/10/2020, 003-K, 8.0 11/12/2020, 101-M, 10.0 11/13/2020, 101-M, 9.0 Note that neither the dates nor employee ids are in any guaranteed order. The program reads in the hours that each employee worked that week and adds the hours to that employee. Note that you will need to find the employee in the array list based on the employee id. Do not make any assumptions about the order of the data. It may be ordered by date, by employee id, or by some other order...or no order at all. Once the information has been read from the files, output the payroll information and any required statistics. Implementation requirements You will need several classes to fulfill the requirements for this assignment. You will need a PayrollManager class which will contain the main method. It is this class that manages the program. It will create the Payroll class. It will call the methods in the Payroll class to load in the employees and hours worked. Finally, it will pull information from the Payroll class (the list of Employees) and print the required output. Note, ONLY the Payroll Manager should do any output (with the exception of error The following is sample output for the data files included with this assignment: Employee type X not supported Id 999-M not found Payroll ID Last 101-M Jaime 111-M Jon 122-M Jorah 123-M Davos Stark 131-M Sansa 132-M Bran Stark 133-M Samwell Tarly 151-M Catelyn Stark Stark 153-M Arya 172-M Daenerys Targaryen 181-M Cersei Lannister Greyjoy 183-M Theon Total Statistics Date 05/17/20 05/18/20 05/19/20 First Lannister Snow Mormont Seaworth 05/20/20 05/21/20 Total Hours 92.00 Hours Wage 12.50 42.00 17.50 42.00 15.00 42.00 15.00 42.00 32.50 42.00 22.00 42.00 17.50 42.00 22.50 38.00 39.50 42.00 42.00 42.00 32.50 42.00 32.50 42.00 500.00 Pay 2318.00 120.00 3010.00 96.00 2408.00 96.00 2408.00 96.00 2408.00 500.00 12552.00 Pay 537.50 735.00 645.00 645.00 1397.50 924.00 735.00 855.00 1698.50 1764.00 1300.00 1300.00 12536.50 Program Two You have been asked to write a payroll program for a small company. They have two files. One contains the employee information. The other contains one week's worth of work hours for the employees. Program operation The program should first open and read all of the employees from the file that lists the employees. The file consists of a single line record for each employee, with each field separated by a comma. This file has the following format: employee id, first name, last name, employee type, salary Sample entries in the file might look like the following. 101-M, Frank, Zappa, H, 22.50 103-J, Mary, McCarthy, E, 32.50 003-K, William, Ramos, C, 32.50 The possibilities for the employee type are H - hourly E - exempt C - contractor The salaries for the employees are per hour. There will also be a second file that holds the hours worked for each employee. This file looks like the following: 11/10/2020, 101-M, 8.0 11/11/2020, 101-M, 8.0 11/10/2020, 103-J, 8.5 11/10/2020, 003-K, 8.0 11/12/2020, 101-M, 10.0 11/13/2020, 101-M, 9.0 Note that neither the dates nor employee ids are in any guaranteed order. The program reads in the hours that each employee worked that week and adds the hours to that employee. Note that you will need to find the employee in the array list based on the employee id. Do not make any assumptions about the order of the data. It may be ordered by date, by employee id, or by some other order...or no order at all. Once the information has been read from the files, output the payroll information and any required statistics. Implementation requirements You will need several classes to fulfill the requirements for this assignment. You will need a PayrollManager class which will contain the main method. It is this class that manages the program. It will create the Payroll class. It will call the methods in the Payroll class to load in the employees and hours worked. Finally, it will pull information from the Payroll class (the list of Employees) and print the required output. Note, ONLY the Payroll Manager should do any output (with the exception of error Program Two You have been asked to write a payroll program for a small company. They have two files. One contains the employee information. The other contains one week's worth of work hours for the employees. Program operation The program should first open and read all of the employees from the file that lists the employees. The file consists of a single line record for each employee, with each field separated by a comma. This file has the following format: employee id, first name, last name, employee type, salary Sample entries in the file might look like the following. 101-M, Frank, Zappa, H, 22.50 103-J, Mary, McCarthy, E, 32.50 003-K, William, Ramos, C, 32.50 The possibilities for the employee type are H - hourly E - exempt C - contractor The salaries for the employees are per hour. There will also be a second file that holds the hours worked for each employee. This file looks like the following: 11/10/2020, 101-M, 8.0 11/11/2020, 101-M, 8.0 11/10/2020, 103-J, 8.5 11/10/2020, 003-K, 8.0 11/12/2020, 101-M, 10.0 11/13/2020, 101-M, 9.0 Note that neither the dates nor employee ids are in any guaranteed order. The program reads in the hours that each employee worked that week and adds the hours to that employee. Note that you will need to find the employee in the array list based on the employee id. Do not make any assumptions about the order of the data. It may be ordered by date, by employee id, or by some other order...or no order at all. Once the information has been read from the files, output the payroll information and any required statistics. Implementation requirements You will need several classes to fulfill the requirements for this assignment. You will need a PayrollManager class which will contain the main method. It is this class that manages the program. It will create the Payroll class. It will call the methods in the Payroll class to load in the employees and hours worked. Finally, it will pull information from the Payroll class (the list of Employees) and print the required output. Note, ONLY the Payroll Manager should do any output (with the exception of error Program Two You have been asked to write a payroll program for a small company. They have two files. One contains the employee information. The other contains one week's worth of work hours for the employees. Program operation The program should first open and read all of the employees from the file that lists the employees. The file consists of a single line record for each employee, with each field separated by a comma. This file has the following format: employee id, first name, last name, employee type, salary Sample entries in the file might look like the following. 101-M, Frank, Zappa, H, 22.50 103-J, Mary, McCarthy, E, 32.50 003-K, William, Ramos, C, 32.50 The possibilities for the employee type are H - hourly E - exempt C - contractor The salaries for the employees are per hour. There will also be a second file that holds the hours worked for each employee. This file looks like the following: 11/10/2020, 101-M, 8.0 11/11/2020, 101-M, 8.0 11/10/2020, 103-J, 8.5 11/10/2020, 003-K, 8.0 11/12/2020, 101-M, 10.0 11/13/2020, 101-M, 9.0 Note that neither the dates nor employee ids are in any guaranteed order. The program reads in the hours that each employee worked that week and adds the hours to that employee. Note that you will need to find the employee in the array list based on the employee id. Do not make any assumptions about the order of the data. It may be ordered by date, by employee id, or by some other order...or no order at all. Once the information has been read from the files, output the payroll information and any required statistics. Implementation requirements You will need several classes to fulfill the requirements for this assignment. You will need a PayrollManager class which will contain the main method. It is this class that manages the program. It will create the Payroll class. It will call the methods in the Payroll class to load in the employees and hours worked. Finally, it will pull information from the Payroll class (the list of Employees) and print the required output. Note, ONLY the Payroll Manager should do any output (with the exception of error The following is sample output for the data files included with this assignment: Employee type X not supported Id 999-M not found Payroll ID Last 101-M Jaime 111-M Jon 122-M Jorah 123-M Davos Stark 131-M Sansa 132-M Bran Stark 133-M Samwell Tarly 151-M Catelyn Stark Stark 153-M Arya 172-M Daenerys Targaryen 181-M Cersei Lannister Greyjoy 183-M Theon Total Statistics Date 05/17/20 05/18/20 05/19/20 First Lannister Snow Mormont Seaworth 05/20/20 05/21/20 Total Hours 92.00 Hours Wage 12.50 42.00 17.50 42.00 15.00 42.00 15.00 42.00 32.50 42.00 22.00 42.00 17.50 42.00 22.50 38.00 39.50 42.00 42.00 42.00 32.50 42.00 32.50 42.00 500.00 Pay 2318.00 120.00 3010.00 96.00 2408.00 96.00 2408.00 96.00 2408.00 500.00 12552.00 Pay 537.50 735.00 645.00 645.00 1397.50 924.00 735.00 855.00 1698.50 1764.00 1300.00 1300.00 12536.50 The following is sample output for the data files included with this assignment: Employee type X not supported Id 999-M not found Payroll ID Last 101-M Jaime 111-M Jon 122-M Jorah 123-M Davos Stark 131-M Sansa 132-M Bran Stark 133-M Samwell Tarly 151-M Catelyn Stark Stark 153-M Arya 172-M Daenerys Targaryen 181-M Cersei Lannister Greyjoy 183-M Theon Total Statistics Date 05/17/20 05/18/20 05/19/20 First Lannister Snow Mormont Seaworth 05/20/20 05/21/20 Total Hours 92.00 Hours Wage 12.50 42.00 17.50 42.00 15.00 42.00 15.00 42.00 32.50 42.00 22.00 42.00 17.50 42.00 22.50 38.00 39.50 42.00 42.00 42.00 32.50 42.00 32.50 42.00 500.00 Pay 2318.00 120.00 3010.00 96.00 2408.00 96.00 2408.00 96.00 2408.00 500.00 12552.00 Pay 537.50 735.00 645.00 645.00 1397.50 924.00 735.00 855.00 1698.50 1764.00 1300.00 1300.00 12536.50 The following is sample output for the data files included with this assignment: Employee type X not supported Id 999-M not found Payroll ID Last 101-M Jaime 111-M Jon 122-M Jorah 123-M Davos Stark 131-M Sansa 132-M Bran Stark 133-M Samwell Tarly 151-M Catelyn Stark Stark 153-M Arya 172-M Daenerys Targaryen 181-M Cersei Lannister Greyjoy 183-M Theon Total Statistics Date 05/17/20 05/18/20 05/19/20 First Lannister Snow Mormont Seaworth 05/20/20 05/21/20 Total Hours 92.00 Hours Wage 12.50 42.00 17.50 42.00 15.00 42.00 15.00 42.00 32.50 42.00 22.00 42.00 17.50 42.00 22.50 38.00 39.50 42.00 42.00 42.00 32.50 42.00 32.50 42.00 500.00 Pay 2318.00 120.00 3010.00 96.00 2408.00 96.00 2408.00 96.00 2408.00 500.00 12552.00 Pay 537.50 735.00 645.00 645.00 1397.50 924.00 735.00 855.00 1698.50 1764.00 1300.00 1300.00 12536.50
Expert Answer:
Related Book For
Business Statistics For Contemporary Decision Making
ISBN: 978-1119320890
9th edition
Authors: Ken Black
Posted Date:
Students also viewed these programming questions
-
re Regular Languages and Finite Automata (a) Let L be the set of all strings over the alphabet {a, b} that end in a and do not contain the substring bb. Describe a deterministic finite automaton...
-
Case Study: Quick Fix Dental Practice Technology requirements Application must be built using Visual Studio 2019 or Visual Studio 2017, professional or enterprise. The community edition is not...
-
On a summer day at Muscat area, the typical average outdoor temperature is 35 degrees Celsius. For the indoor temperature of a house to be kept constant a temperature of 24 degrees Celsius, the rate...
-
At the end of each year, you plan to deposit $2,000 in a savings account. The account will earn 9% annual interest, which will be added to the fund balance at year-end. The first deposit will be made...
-
In its income statement for the year ended December 31, 2022, Shamrock Inc. reported the following condensed data. Operating expenses $812,000 Interest revenue $ 36,960 Cost of goods sold 1,406,720...
-
What are the advantages and disadvantages of certified environmental product declarations? Assuming that you are the environmental manager of Global Autos, with companies operating in Sweden,...
-
Stacy Yoo, president of Caremore, Inc., an appliance manufacturer in Seattle, Washington, has been trying to decide whether one of her product-line managers, Bill Mann, has been achieving the...
-
E24.1 The surface area of S is given by s 1 dS = \u v\dudv, where D is the domain of integration on the u-v plane. (We will talk about why this is true on Friday. ) Let S be the part of the...
-
The Alfredo Fragrance Company produces only one product, a perfume called Hint of Elegance. Hint of Elegance consists of two secret ingredients blended into an exclusive fragrance, which is marketed...
-
If you have recently had a loan application declined, what things could you do to improve the next loan application? Discuss.
-
Calculate the following definite integral, correct to two decimal places: cosxsinx dr where k = 0.11. The limits on the integral are in radians.
-
2. (4 pts) Given the following declarations and statements, write an appropriate function call for the function implemented above. The value returned from the function should be stored in variable...
-
What is a mobile operating system? Why is the Google Android OS has the current market share majority? Envision the perfect mobile OS and mobile device. What features would it have that current...
-
For the given function f(x) = (4)* describe the transformations, that must be applied to get h(x)=-3(4)3x-9-5
-
4. Given the recursive function definition: g(n) = 2 * g(n-1) + 4 * g(n-2) a. Evaluate: g(3) g(0) = 0 g(1) = 1
-
10 mol/h of benzene (CH) and 20 mol/h of chlorine gas (Cl) are fed to a reactor. Chlorobenzene (C6HCl), di-chlorobenzene (CHCl), and tri-chlorobenzene (CH-C(3) are main products from the process. The...
-
A Bloomberg Businessweek subscriber study asked, In the past 12 months, when traveling for business, what type of airline ticket did you purchase most often? A second question asked if the type of...
-
Using the Hospital database, construct a 90% confidence interval to estimate the average census for hospitals. Change the level of confidence to 99%. What happened to the interval? Did the point...
-
In the Manufacturing database, what is the probability that a randomly selected SIC Code industry is in industry group 13? What is the probability that a randomly selected SIC Code industry has a...
-
Using the Manufacturing database as a sample, construct a 95% confidence interval for the population mean number of production workers. What is the point estimate? How much is the error of the...
-
The slider-crank mechanism of Sample Problem 5/9 is repeated here. The crank \(O B\) has a constant clockwise angular speed of \(1500 \mathrm{rev} / \mathrm{min}\). For the instant when the crank...
-
The pin \(A\) of the hinged link \(A C\) is confined to move in the rotating slot of link \(O D\). The angular velocity of \(O D\) is \(\omega=2 \mathrm{rad} / \mathrm{s}\) clockwise and is constant...
-
At the instant represented, the disk with the radial slot is rotating about \(O\) with a counterclockwise angular velocity of \(4 \mathrm{rad} / \mathrm{sec}\) which is decreasing at the rate of \(10...
Study smarter with the SolutionInn App