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
Licemer1 [7]
3 years ago
10

Create a program to calculate the wage. Assume people are paid double time for hours over 60 a week. Therefore they get paid for

at most 20 hours overtime at 1.5 times the normal rate. For example, a person working 70 hours with a regular wage of $20 per hour would work at $20 per hour for 40 hours, at 1.5 * $20 for 20 hours of overtime, and 2 * $20 for 10 hours of double time. For the total wage will be:
20 * 40 + 1.5 * 20 * 20 + 2 * 20 * 10 = 1800

The program shall include the following features:

a. Prompt the user to enter the name, regular wage, and how many work he/she has worked for the week.
b. Print the following information:NameRegular wageHours worked in one weekTotal wage of the week
Computers and Technology
1 answer:
Rus_ich [418]3 years ago
4 0

Answer:

Written in Python

name = input("Name: ")

wageHours = int(input("Hours: "))

regPay = float(input("Wages: "))

if wageHours >= 60:

->total = (wageHours - 60) * 2 * regPay + 20 * 1.5 * regPay + regPay * 40

else:

->total = wageHours * regPay

print(name)

print(wageHours)

print(regPay)

print(total)

Explanation:

The program is self-explanatory.

However,

On line 4, the program checks if wageHours is greater than 60.

If yes, the corresponding wage is calculated.

On line 6, if workHours is not up to 60, the total wages is calculated by multiplying workHours by regPay, since there's no provision for how to calculate total wages for hours less than 60

The required details is printed afterwards

Note that -> represents indentation

You might be interested in
Suppose that outFileis an ofstreamvariable and output is to be stored in the file outputData.out. Which of the following stateme
BlackZzzverrR [31]

Answer:

Option b outFile.open("outputData.out");

Explanation:

In C++, there are several classes given to handle output and input of characters to or from files. They are:

  • ofstream that write on files
  • ifstream that read from files

We can use an object of ofstream to hold the contents that we wish to output to an external file. The general syntax is as follows:

           ofstream_obj.open(file_name)

This will create a file with a specific file name and it possesses all the contents from the obstream_obj.

5 0
2 years ago
What do you understand by storage devices ? Name any two storage devices.​
MatroZZZ [7]

Answer:

Types of storage devices

Primary Storage: Random Access Memory (RAM) Random Access Memory, or RAM, is the primary storage of a computer. ...

Secondary Storage: Hard Disk Drives (HDD) & Solid-State Drives (SSD) ...

Hard Disk Drives (HDD) ...

Solid-State Drives (SSD) ...

External HDDs and SSDs. ...

Flash memory devices. ...

Optical Storage Devices. ...

Floppy Disks.

6 0
3 years ago
Read 2 more answers
Complete the following sentences with the correct form of the verbs in brackets.
Rina8888 [55]

Answer:

1. don't pass, will be

2. will get, eat

3. don't help, won't help

4. are meeting, will you go?

5. will stay, rains

Is

6.Will

Puts on

7.Will go

Asks

8.Will... tell

9.Tell

Will

10.Go... Will find out...

Explanation:

5 0
2 years ago
Pig Latin is ______ and fits very naturally in the pipeline paradigm while SQL is instead declarative.
alisha [4.7K]

Answer:

Option b) is correct

Explanation:

Pig Latin is a language game in which English words are altered either by adding a suffix or such kind of suffix can be created by adding a syllable (vocalic). For example, ''hello'' becomes ''ello-hay''.

Pig Latin is <u>procedural</u> and fits very naturally in the pipeline paradigm while SQL is instead declarative.

3 0
2 years ago
Select the correct answer. Which input device uses optical technology?
daser333 [38]

Answer:

barcode reader is the correct answer

8 0
2 years ago
Other questions:
  • In a paragraph of no less than 125 words, describe how you would insert a graph in your word-processing document.
    8·2 answers
  • One of the most studied computational problems is the ordering of a collection of values. Ordering is important because many pro
    15·1 answer
  • Which device on a network performs network address translation?
    8·1 answer
  • Recursion is a natural use for a _____ (stack or queue)
    13·1 answer
  • You have added a table to your web page consisting of two columns and five rows, including the header row. in the first header c
    13·1 answer
  • When searching the web software programs called fetch a few web pages and then they follow the links on those pages and fetch th
    9·2 answers
  • What kind of app or technology would you like to create?  Why ? <br><br><br>​
    11·1 answer
  • What is it called when you remove some information from a file or remove a file from the disk ? A) save b) delete c) edit d) rem
    5·1 answer
  • How to make a website
    15·2 answers
  • What is the suffix of hollow?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!