Question

An employee’s total weekly pay equals the hourly wage multiplied by the total number of regular hours plus any. Overtime pay equals the total overtime hours multiplied by 1.5 times the hourly wage. Write a program that takes as input the hourly wage. Total regular hours. And total overtime hours and displays an employee’s total weekly pay.

Answer #1

#include <iostream>

using namespace std;

int main()

{

double n,p,h,e;

cout<<"Enter the hourly wage: ";

cin>>p; //Taking wages from user

cout<<"Enter the regular hours: ";

cin>>h; //Taking no of regular hours

cout<<"Enter the no of extra hours: ";

cin>>e; //Taking no of extra hours

n = p * h + (p * 1.5 * e); //Calculating weekly pay

cout<<"Total weekly pay is: "<<n; //Printing weekly
pay

return 0;

}

Output:-

Python Coding
Federal law requires that hourly employees be paid “time and a
half” for all work above 40 hours per week. Write a program that
prompts the user to enter their hours worked and hourly wage (e.g.
$20.00/hr) and then computes and prints their pay. The program
should test the number of hours worked to determine if any overtime
pay is due.
As an example for regular pay (no overtime) suppose that a
worker makes $10/hr and works 40...

Jaflin Garza's regular hourly wage rate is $13.50, and she
receives a wage of 1½ times the regular hourly rate for work in
excess of 40 hours. During a March weekly pay period, Jaflin worked
42 hours. Her gross earnings prior to the current week were $5,800.
Jaflin is married and claims three withholding allowances. Her only
voluntary deduction is for group hospitalization insurance at $20
per week.
gross earnings 580.50
fica tax 44.41
fit withheld 19.00
state income tax...

Design a PayRoll class that has data members for an employee’s
hourly pay rate, number of hours worked of type double. The default
constructor will set the hours worked and pay rate to zero. The
class must have a mutator function to set the pay rate for each
employee and hours worked. The class should include accessors for
both the hours worked and the rate of pay. The class should lastly
have a getGross function that will return a double...

Create a C# application
You are to create a class object called “Employee” which
included eight private variables:
firstN
lastN
dNum
wage: holds how much the person makes per hour
weekHrsWkd: holds how many total hours the person worked each
week.
regHrsAmt: initialize to a fixed amount of 40 using
constructor.
regPay
otPay
After going over the regular hours, the employee gets 1.5x the
wage for each additional hour worked.
Methods:
constructor
properties
CalcPay(): Calculate the regular...

Sheila Williams, a
medical secretary, earns $2,600 monthly for a 36-hour week. For
overtime work, she receives extra pay at the regular hourly rate up
to 40 hours and time and one-half beyond 40 hours in any week.
During one semimonthly pay period, Williams worked 10 hours
overtime. Only 2 hours of this overtime were beyond 40 hours in any
one week. Compute the following amounts.
Round all
divisions to two decimal places and use the rounded amounts in
subsequent...

Note: In this chapter and in all succeeding work throughout the
course, unless instructed otherwise, calculate hourly rates and
overtime rates as follows: 1. Carry the hourly rate and the
overtime rate to 3 decimal places and then round off to 2 decimal
places (round the hourly rate to 2 decimal places before
multiplying by one and one-half to determine the overtime rate). 2.
If the third decimal place is 5 or more, round to the next higher
cent. 3....

Prepare a worksheet that allows the user to enter ONLY
these fields: Start Time and End Time per day on a 5
day workweek (10 cells) and Hourly Wage (1 cell),
Total Hours Worked (1 cell), and Total Earnings (1
cell). So there should ONLY be 13 data entry fields for
the user. Each of those fields should have a title, so
there should be an additional 13 title cells
explaining each data cell. Make sure that the title
fields are properly labeled. So, there should be 26 cells used in
total.
The user will...

Calculate Payroll
Breakin Away Company has three employees—a consultant, a
computer programmer, and an administrator. The following payroll
information is available for each employee:
Consultant
Computer Programmer
Administrator
Regular earnings rate
$4,000 per week
$60 per hour
$50 per hour
Overtime earnings rate*
Not applicable
1.5 times hourly rate
2 times hourly rate
Number of withholding allowances
2
1
2
*For hourly employees, overtime is paid for hours
worked in excess of 40 hours per week.
For the current pay...

Breakin Away Company
has three employees—a consultant, a computer programmer, and an
administrator. The following payroll information is available for
each employee:
Consultant
Computer Programmer
Administrator
Regular earnings rate
$4,000 per week
$60 per hour
$50 per hour
Overtime earnings rate*
Not applicable
1.5 times hourly rate
2 times hourly rate
Number of withholding allowances
2
1
2
* For hourly employees, overtime is paid for hours
worked in excess of 40 hours per week.
For the current pay
period,...

Calculate gross pay for each of the following employees. All are
paid an overtime wage rate that is 1.5 times their respective
regular wage rates. NOTE: For simplicity, all calculations
throughout this exercise, both intermediate and final, should be
rounded to two decimal places at each calculation.
1: Amy Blackwood receives tips from customers as a standard
component of her weekly pay. She is paid $2.25/hour by her employer
and receives $175 in tips during the most recent 48-hour workweek....

ADVERTISEMENT

Get Answers For Free

Most questions answered within 1 hours.

ADVERTISEMENT

asked 38 minutes ago

asked 42 minutes ago

asked 58 minutes ago

asked 1 hour ago

asked 1 hour ago

asked 1 hour ago

asked 1 hour ago

asked 1 hour ago

asked 2 hours ago

asked 2 hours ago

asked 2 hours ago

asked 3 hours ago