Answered step by step
Verified Expert Solution
Question
1 Approved Answer
c++ using visual studio Problem Description: WVU needs a payroll application, which has the capability to calculate and print the monthly pay of an employee.
c++ using visual studio
Problem Description: WVU needs a payroll application, which has the capability to calculate and print the monthly pay of an employee. The application starts by printing a short description of what it does. Then, it asks for the employee name. Next, the application prompts for employee type ("H" for hourly and "S" for salaried.) If the user enters S, the gross pay is set to $4000. However, if the user enters H for an hourly employee, the application asks for the number of hours worked and the hourly rate and these are used to calculate the gross pay. The deductions from the paycheck before tax cuts are contributions to health insurance ($300) and retirement plan (6%). The federal income tax (15%) and state income tax (5%) are deducted after the contributions to health and retirement are deducted from the gross pay. A sample payslip for each kind of employee is shown in the screenshots below. Make sure your application's output is similar or better than the screenshots given below. Salaried Employee Payslip Sample: This application calculates the salary of an employee based on their employnent status Enter the nane of the enployee : Jose Sartarelli Enter the employee type CH for hourly. S for salaried) : S Payslip - Jose Sartarelli Gross Pay : $4,000.00 Contributions Health Insurance : $380.80 Retirenent Plan (6%) : $240.90 Pay After Contributions : $3.460.00 Federal Tax (15%) $519.00 State Tax (5%) : $173.00 Net Pay : $2.268.00 Hourly Employee Payslip Sample: This application calculates the salary of an employee based on their employnent status Enter the nane of the employee : Salman Nazir Enter the employee type CH for hourly. S for salaried) : H Enter the number of hours worked : 120 Enter the hourly rate : 45 Payslip Salman Nazir Gross Pay : $5.400.00 Contributions Health Insurance : $300.00 Retirement Plan (6%> : $324.00 Pay After Contributions : $4,726.00 Federal Tax (15%) : $216.40 State Tax (5%) : $238.80 Net Pay : $3,820.88 BI : 99+ It A Technical Specifications The application must contain your name and student number as well the purpose of the program in the top section of each class file (as comments). You should explain your code by providing adequate commenting. You will need two class files for this application. One will be called Payroll and the other PayrollTest The program must ask for the name, and the employee type. The name and employee type should be stored as instance variables with appropriate properties. You will also need another instance variable to store the Gross Pay of the employee. The value for this variable will depend on the type of employee. If the employee is an hourly employee it should ask for the number of hours worked, and the hourly rate for the employee to calculate the gross pay. The program must then process the information and output it as shown in the samples above. All processing of the Net Pay will be done by a method in the Payroll class. All output must be printed by a method in the Payroll class. The output must print: Payslip Header o The Gross Pay amount (rounded to two decimal places) o The contributions to health and retirement plans and the federal and state tax amounts. And finally, the net pay amount (rounded to two decimal places) The code must be in line with the programming standards covered in class. The code must compile and the output should be very similar to that shown in the screenshots above using System 3 4 Enamespace Payroll 5 class Payrol Bree static void Main(strinet ars) B 991 10 12 Nos found Problem Description: WVU needs a payroll application, which has the capability to calculate and print the monthly pay of an employee. The application starts by printing a short description of what it does. Then, it asks for the employee name. Next, the application prompts for employee type ("H" for hourly and "S" for salaried.) If the user enters S, the gross pay is set to $4000. However, if the user enters H for an hourly employee, the application asks for the number of hours worked and the hourly rate and these are used to calculate the gross pay. The deductions from the paycheck before tax cuts are contributions to health insurance ($300) and retirement plan (6%). The federal income tax (15%) and state income tax (5%) are deducted after the contributions to health and retirement are deducted from the gross pay. A sample payslip for each kind of employee is shown in the screenshots below. Make sure your application's output is similar or better than the screenshots given below. Salaried Employee Payslip Sample: This application calculates the salary of an employee based on their employnent status Enter the nane of the enployee : Jose Sartarelli Enter the employee type CH for hourly. S for salaried) : S Payslip - Jose Sartarelli Gross Pay : $4,000.00 Contributions Health Insurance : $380.80 Retirenent Plan (6%) : $240.90 Pay After Contributions : $3.460.00 Federal Tax (15%) $519.00 State Tax (5%) : $173.00 Net Pay : $2.268.00 Hourly Employee Payslip Sample: This application calculates the salary of an employee based on their employnent status Enter the nane of the employee : Salman Nazir Enter the employee type CH for hourly. S for salaried) : H Enter the number of hours worked : 120 Enter the hourly rate : 45 Payslip Salman Nazir Gross Pay : $5.400.00 Contributions Health Insurance : $300.00 Retirement Plan (6%> : $324.00 Pay After Contributions : $4,726.00 Federal Tax (15%) : $216.40 State Tax (5%) : $238.80 Net Pay : $3,820.88 BI : 99+ It A Technical Specifications The application must contain your name and student number as well the purpose of the program in the top section of each class file (as comments). You should explain your code by providing adequate commenting. You will need two class files for this application. One will be called Payroll and the other PayrollTest The program must ask for the name, and the employee type. The name and employee type should be stored as instance variables with appropriate properties. You will also need another instance variable to store the Gross Pay of the employee. The value for this variable will depend on the type of employee. If the employee is an hourly employee it should ask for the number of hours worked, and the hourly rate for the employee to calculate the gross pay. The program must then process the information and output it as shown in the samples above. All processing of the Net Pay will be done by a method in the Payroll class. All output must be printed by a method in the Payroll class. The output must print: Payslip Header o The Gross Pay amount (rounded to two decimal places) o The contributions to health and retirement plans and the federal and state tax amounts. And finally, the net pay amount (rounded to two decimal places) The code must be in line with the programming standards covered in class. The code must compile and the output should be very similar to that shown in the screenshots above using System 3 4 Enamespace Payroll 5 class Payrol Bree static void Main(strinet ars) B 991 10 12 Nos found Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started