Menu

[Solved]Please Solve Following Please Hand Write Make Sure Type Everything Problem Requirements Mu Q37129016

Please solve the following, please do not hand write, and makesure to type out everything. With each problem, there are”requirements” it must meet. I will attach them. Thank you!

Problem 2 The We-Say-So Corporation needs a program to calculate how much to pay their hourly employees. US labor laws state

Problem 2: Compile and Run If your file can be compiled by javac complier, you will get full make. Problem 2: Pass minimum wa

Problem 2 The We-Say-So Corporation needs a program to calculate how much to pay their hourly employees. US labor laws state that hourly employees should be paid time and a half for any hours over 40 that they work in a single week. So for example, if an employee works for 46 hours in a week, then they get 6 hours of overtime, at 1.5 times their base pay. The We-Say-So Corp. is based in a state where the minimum wage is 5.25 dollars per hour. It is company policy that employees should not work for more than 60 hours in a single week. in a class called H2P2 a)Write a method called salaryTotal that takes two inputs: the base pay and hours worked in a week as parameters, and either returns the total pay, -1 if base pays is less than minimum wage, or -2 if number of hours worked is more than 60. b) Also, write a main method that asks the user (a manager, presumably) to input the full name, the base pay and the hours worked in a week for a particular employee using the keyboard (separated by commas and in this order). main should use salaryTotal to compute the total pay for that employee and then print one of the following messages to the screen: The total pay for <full name> is <total pays dollars. or The number of hours your entered does not comply with company policy. or The base salary you entered does not comply with state law. Problem 2: Compile and Run If your file can be compiled by javac complier, you will get full make. Problem 2: Pass minimum wage test Test: enter 1 as hourly rate and get the right error message Problem 2: Pass overtime test Test: enter 100 as hours and get the right error message Problem 2: Return the right amount Test 1: enter 10, 10 and get $100 as salary Test 2: enter 10, 45 and get $475 as salary Problem 2: Main Your instruction is clear and salaryTotal return double Show transcribed image text Problem 2 The We-Say-So Corporation needs a program to calculate how much to pay their hourly employees. US labor laws state that hourly employees should be paid time and a half for any hours over 40 that they work in a single week. So for example, if an employee works for 46 hours in a week, then they get 6 hours of overtime, at 1.5 times their base pay. The We-Say-So Corp. is based in a state where the minimum wage is 5.25 dollars per hour. It is company policy that employees should not work for more than 60 hours in a single week. in a class called H2P2 a)Write a method called salaryTotal that takes two inputs: the base pay and hours worked in a week as parameters, and either returns the total pay, -1 if base pays is less than minimum wage, or -2 if number of hours worked is more than 60. b) Also, write a main method that asks the user (a manager, presumably) to input the full name, the base pay and the hours worked in a week for a particular employee using the keyboard (separated by commas and in this order). main should use salaryTotal to compute the total pay for that employee and then print one of the following messages to the screen: The total pay for is

Expert Answer


Answer to Please solve the following, please do not hand write, and make sure to type out everything. With each problem, there are… . . .

OR


Leave a Reply

Your email address will not be published. Required fields are marked *