1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
ss7ja [257]
3 years ago
14

. Acme Parts runs a small factory and employs workers who are paid one of three hourly rates depending on their shift: first shi

ft, $17 per hour; second shift, $18.50 per hour; third shift, $22 per hour. Each factory worker might work any number of hours per week; any hours greater than 40 are paid at one and one-half times the usual rate. In addition, second- and third-shift workers can elect to participate in the retirement plan for which 3% of the worker’s gross pay is deducted from the paychecks. Write a program that prompts the user for hours worked and shift, and, if the shift is 2 or 3, whether the worker elects the retirement. Display: (1) the hours worked, (2) the shift, (3) the hourly pay rate, (4) the regular pay, (5) overtime pay, (6) the total of regular and overtime pay, and (7) the retirement deduction, if any, and (8) the net pay. Save the file as AcmePay.java.
Business
1 answer:
attashe74 [19]3 years ago
5 0

Answer:

Program file

filename: AcmePay.java

import java.util.Scanner;

public class Payroll {

public static void main(String[] args) {

double[] shiftPay = { 17, 18.50, 22 };

double hourlyPayRate = 0, regularPay = 0, overTimeHours = 0, overTimePay = 0, retirementDeduction = 0,

netPay = 0;

System.out.println("*** Employee Pay ***");

// scanner object to read data

Scanner scan = new Scanner(System.in);

// read the number of hours worked from user

System.out.print("Enter the number of hours worked: ");

double numHours = scan.nextDouble();

// read the shift

System.out.print("Enter the shift (1 - 3): ");

int shift = scan.nextInt();

hourlyPayRate = shiftPay[shift];

// calculate regulaPay

regularPay = numHours * hourlyPayRate;

if (numHours > 40) {

overTimeHours = numHours - 40;

overTimePay = overTimeHours * (hourlyPayRate * 1.5);

}

// calculate grossPay

double grossPay = regularPay + overTimePay;

// check for availability of retirement plan

if (shift == 2 || shift == 3) {

System.out.print("Did the worker elected for retirement (1 for yes, 2 for no): ");

int chooseRetirement = scan.nextInt();

if (chooseRetirement == 1) {

// calculate retirement bonus

retirementDeduction = (grossPay * 0.03);

}

}

// calculate netPay

netPay = grossPay - retirementDeduction;

// print the information to stdout

System.out.println("Hours worked: " + numHours);

System.out.println("Shift: " + shift);

System.out.println("Hourly Pay rate: " + hourlyPayRate);

System.out.println("Regular Pay: " + regularPay);

System.out.println("Overtime hours: " + overTimeHours);

System.out.println("Overtime pay: " + overTimePay);

System.out.println("Total of regular and overtime pay (Gross pay): " + grossPay);

System.out.println("Retirement deduction, if any: " + retirementDeduction);

System.out.println("Net pay: " + netPay);

// close scanner object

scan.close();

}

}

Explanation:

You might be interested in
Carol works for firm x. she takes long breaks and often daydreams when she is being paid to work. carol is
lakkis [162]
The answer is A because she could be watching people while daydreaming
6 0
3 years ago
Suppose that Rearden Metal currently has no debt and has an equity cost of capital of 12%. Rearden is considering borrowing fund
Alexxandr [17]

Answer:

Option (C) is correct.

Explanation:

We have to use MM proposition that cost of equity will change itself in such a manner so that it can take care of its debt.

Cost of equity:

= WACC of all equity firm + (WACC of all equity - Cost of debt ) × (Debt -to-equity ratio)

At the beginning, when there was no debt,

WACC = cost of equity = 12 %

Levered cost of equity:

= 12% + ( 12% - 6%) × 0.5

= 15%

Therefore, Rearden's levered cost of equity would be closest to 15%.

4 0
4 years ago
Playwrights that have been quoted as serving as the initial director of their work are
Scorpion4ik [409]
Among the novelists, these are the those that served the initial director of their work: Samuel B<span>eckett, Bertolt Brecht, David Mamet, </span><span>George Bernard </span><span>Shaw</span>, Sam Shepard and the most famous novelist, William Shakespeare. After Shakespeare's time, playwrights are already considered as independent artists.
6 0
3 years ago
What type of international risk exposure measures the change in present value of a firm resulting from changes in future operati
Alex787 [66]

Answer:

operating exposure

Explanation:

Based on the scenario being described within the question it can be said that the term being mentioned is known as operating exposure and deals with the company's operations over various months or years and the changes incurred due to unexpected changes in the exchange rate. The exchange rate is the price at which one currency is traded for another. Drastic changes in these rates can cause assets value to decline drastically.

4 0
3 years ago
A factor favoring the success of disruptive innovation is that:________.
ankoles [38]

Answer:

A) incumbent firms are slow to change.

Explanation:

This business model type is said to be low cost and also can be seen and tested to be highly accessible to buyers and others goods in the market. Disruptive innovation is a business model that deals with the introduction of a new product or service into a market, at a lower cost and affordable that other products or its competitors, hereby luring prospective or buyers to buying the new product; displacing the leaders or top performers in the market. Disruptive innovation is highly favoured because the incumbent firms are slow to change.

8 0
3 years ago
Other questions:
  • _____ is the efficient and effective execution of specific tasks. a. wisdom b. expertise c. strategic planning d. operational co
    10·1 answer
  • Assume you are participating in your employer's direct deposit program. On payday, the employer deposits your ________ into you
    11·2 answers
  • When the amount paid for land is $36,000 and the amount paid for expenses is $10,000, the balance in total assets after transact
    12·1 answer
  • Hello friends , please follow me so that we can be friends.
    15·2 answers
  • Morgan Co. signs a $50,000 noninterest-bearing 5-year note payable for goods purchased from Xelco Industries. The appropriate ra
    8·1 answer
  • What is a business idea?
    14·2 answers
  • Carver Company produces a product which sells for $30. Variable manufacturing costs are $15 per unit. Fixed manufacturing costs
    10·1 answer
  • An economic system that allows indivduals to pursue their own interests without undue
    7·1 answer
  • Jason is an author who works for a variety of publishing companies. One of them recently informed him that they will no longer b
    9·1 answer
  • l a fixed asset for $72,376 when its book value is $43,070. If your company's marginal tax rate is 25 percent, what will be the
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!