Question: Exercise #4: Write a Java program which reads the input from a file and calculates and prints the monthly paycheck for an employee to a
Exercise #4: Write a Java program which reads the input from a file and calculates and prints the monthly paycheck for an employee to a file or files. The program depends on the number of lines in the input file, one ouput file per line in input file. In other words, for multiple employees, the program will result in multiple files given multiple input salaries in the input file. For net salary, the following deductions and additions are required during calculation step: Deducations: Additions: Retirement Plan: 5% Housing Allowence: 20% Health Insurance: 750 AED Transportation Allowence: 200 Your Java program should read the input gross amount from input file. The format for input and output file should be like this: Input File Sample: 10000 Output File Sample: Gross Amount: 10000.00 Retirement Plan: Health Insurance: Housing Allowence: Transportation Allowence: 500.00 AED 750.00 AED + 2000.00 AED + 200.00 AED Net Salary: 10950.00 AED
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
