Question: Kindly help in solving this question. The question has to be done in Java language only. Do not use pointers. Program Name: HoursCalculator.java [25 Points]
Kindly help in solving this question.
The question has to be done in Java language only.
Do not use pointers.
![Program Name: HoursCalculator.java [25 Points] A software house named AppsSolution needs a](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/01/65ba67bb7759d_06765ba67bb43437.jpg)

Program Name: HoursCalculator.java [25 Points] A software house named AppsSolution needs a program to calculate how much to hours their contractual and interns employees worked. Interns: the interns get paid time and a half for any hours over 20 that they work in a single week. For example, if an interns works 25 hours, they get 5 hours of overtime, at 1.5 times their base pay. The base should be at least RS. 250 an hour. This Apps Solution requires that an intern does not work more than 30 hours in a week. Contractual: They get paid time and a half for any hours over 30 that they work in a single week. For example, if an employee works 33 hours, they get 3 hours of overtime, at 1.5 times their base pay. Their base pay should not be less than RS. 300 an hour. This AppsSolution requires that an employee does not work more than 40 hours in a week. To sum up: An employee gets paid (hours worked) x (base pay) for each hour up to 20 or 30 hours depending upon employee type. For every hour over 20 or 30 depending upon employee type, they get overtime = Overtime hours x (base pay) x 1.5. The base pay must not be less than the minimum wage (RS. 250 or RS. 300 an hour depending upon employee type). The working hours must not exceed 40 or 30 depending upon employee type. Write a program that ask user to enter Employee Name, Employee type (Interns/Contractual), salary and base pay. You need to write the following methods: 1. Write a method that validates the input that if it is in given range or not. public static boolean isValidInput (Char empType, double salary, double basePay) 2. A method that calculate hours based on given parameters. public static double calculateHours (Char empType, double salary, int baseHours, double basePay) 3. A method to calculate overtime hours. This method should be called from calculateHours if and when required. public static double calculateOverTimeHours (int OverTime Salary, double baseHour)
Step by Step Solution
3.37 Rating (144 Votes )
There are 3 Steps involved in it
Heres the Java code for the Hours Calculator program import javautilScanner public class HoursCalcul... View full answer
Get step-by-step solutions from verified subject matter experts
