Design a payroll program that prompts user enter an employee's hourly pay rate and the number of hours worked. Validate user's input so that only pay rates in the range of $7.5 through $18.25 and hours in the range of 0.5 through 40 are acceptable. If user enters validate data in less than three tries, the program calculate and display gross pay, otherwise tell user the program will be terminated because of too many invalid input. Please provide step by step solution for this problem!

Question

Design a payroll program that prompts user enter an employee's hourly pay rate and the number of hours worked. Validate user's input so that only pay rates in the range of $7.5 through $18.25 and hours in the range of 0.5 through 40 are acceptable. If user enters validate data in less than three tries, the program calculate and display gross pay, otherwise tell user the program will be terminated because of too many invalid input.

Please provide step by step solution for this problem! 

Expert Answer

Want to see the step-by-step answer?

Check out a sample Q&A here.

Want to see this answer and more?

Experts are waiting 24/7 to provide step-by-step solutions in as fast as 30 minutes!*

*Response times may vary by subject and question complexity. Median response time is 34 minutes for paid subscribers and may be longer for promotional offers.
Tagged in
Engineering
Computer Science

Programing Language

Related Computer Science Q&A

Find answers to questions asked by students like you.

Q: I am trying to get the range of bits from a number. For example , if I call bitRange(0x00001234, 0 ,...

A: Step 1: To extract the bits from the hexadecimal number we need to use the shift operator and use bi...

Q: Create a PL/SQL block to calculate factorial of a number entered from the screen by the user. If the...

A: The PL/SQL block to calculate factorial of a number entered from the screen by the user is given bel...

Q: List the octal and hexadecimal numbers from 1410 to 3210. Using A and B for the last two digits, lis...

A: Answer:Listing octal values from 1410 to 3210:Divide 14 by 8 (octal number) giving 1 remainder 61 is...

Q: Draw a full-adder using only NAND gates.

A: The full adder circuit with NAND gates is shown below.  It is a simple 1 bit adder.

Q: Eliminate all λ-productions from S → AaB|aaB, A → λ, B → bbA|λ.

A: A procedure of removing all λ productions is as follows:

Q: 12 4x)x,is an another form of representation of fuzzy set. A, (x) /x, is an another form of represen...

A: A fuzzy set is a pair X, m(A)) where X is a Universal set and mA) is a membership function or degree...

Q: For problem 10RQ for Business Informaiton Systems book by Paige Baltzan, the question asked what is ...

A: The terms Collective intelligence, Knowledge management and Crowdsourcing are related to each other ...

Q: what is the best test strategy for any ERP system?

A: ERP stands for Enterprise resource planning is a software used for business process management. It a...

Q: Programming in C language.

A: In order to implement the question mentions a method called getChoice() information about which has ...

Q: C++ Thanks!Example:"apple"->NULLreturn "apple"->NULL"apple"->"apple"->NULLreturn "apple"...

A: So in the fisrt step we will make the current node value is head.node* current = head;

Q: Do you think technologies like Big Data and Predictive Analytics in Marketing would have worked 10-1...

A: The technologies like Big Data would not have worked 10-15 years back as due to lack of large datase...

Q: Create the physical level ERD.  I believe my physical level ERD is missing several parts. However, t...

A: Hey.....The actual design of database can be represented  by  physical E- R   diagrams.Physical ERD ...

Q: Write a program in Eclipse that prompts the user to enter a string and displays the number of vowels...

A: Solution:Given data, The java code gets the input string from user and display the number of vowels ...

Q: Create a trigger called Trig_Enroll_BI on the ENROLLMENT table that fires before an INSERT statement...

A: Solution:Create the trigger with name of “Trig_Enroll_BI” for ENROLLMENT table.The followings algori...

Q: Draw a half-adder using only NAND gates.

A: Half adder is basically a combinational circuit which executes simple basic addition of two binary n...

Q: Programming in C.

A: Note: The below program has been complied and executed in "repl.it" online complier

Q: Develop pseudocode for the problem of reading in the radius of a circle (r), calculate the area of t...

A: The program will have the following steps:Receive the input as a parameter passed to the function wh...

Q: Consider the Sort-and-Count algorithm explained in section 5.3 of our text: "Counting Inversions"Sup...

A: Given:Initial list:26   81   87   32   66   72   86   97   23   48   14   71   89   18   49   62Algo...

Q: Show that the language L = {w : na (w) = nb (w)} is not regular. Is L∗ regular?

A: Solution:Given that,L = {w: na(w) = nb(w)}Justification:Use the pumping lemma theorem to verify a la...

Q: Assume that you have been tasked by your employer to develop an incident response plan. Create a lis...

A: Stakeholder:A stakeholder can be a person, a group, or an organization that has an affair or matter ...

Q: Visual Basic. Write the definition of a function named quadratic that receives three double paramete...

A: Formula for quadratic equation:

Q: Help.

A: Below is the algorithm:-start    function quadratic(a,b,c)        if a=0 then            display "no...

Q: What would the output be when the user taps or clicks the btnDrivingAge button   Private Sub btnDri...

A: Form1:

Q: Write a PL/SQL block to retrieve and display the students enrolled in a course.

A: Click to see the answer

Q: Hello! I am trying to write a program in Pynthon. Need help. Requirements: Write a .py file like Kev...

A: Program Plan:Import required packagesPrompt the path and the number of characters to delete from the...

Q: Nine coins are placed in a 3x3 matrix with some face up and some face down. You can represent the st...

A: As there is no programming language mentioned, we are writing this program in JAVA. The program is g...

Q: Write a function is_mirror(s) that takes as input a string s and returns True if s is a mirrored str...

A: The algorithm for the program would be as follows:Find the length of the program if it is even lengt...

Q: (The Fan class) Design a class named Fan to represent a fan. The class contains:■ Three constants na...

A: Java program to create Fan class is as follows:

Q: Use the worksheets to show, one path augmentation at a time, how to use the Ford-Fulkerson Algorithm...

A: For solving your problem first of all we define Ford-Fulkerson Algorithm.Ford-Fulkerson Algorithm fo...

Q: How to use ProstgreSQL in my local Java IDE using SSH tunneling?

A: So here we have to do three things,1) first we need to create a SSH tunnel to the postgreSQL db but ...

Q: do big data could replace the artistic vision of a creative director? and why?

A: Justification:“Yes”, big data replace the artistic vision of a creative director.

Q: Problem: Create a base class called Vehicle that has the manufacturer’s name (typeString), number of...

A: Program plan:Create a class called “Person” with required constructors and methods.Create a class ca...

Q: Please write Lisp code for the following problem. Consider the list:((name (number1 nation)) (MusicP...

A: Instructions to create a function to access the MovieTixHighPrices value using car and cdr:The funct...

Q: How become a ggod programmer?

A: Good programmer:Becoming programmer is not a big thing; it is all about learning the logics of the p...

Q: Hi,please I need to use Python for the following: Use for loop to do the following: 1) print the num...

A: Program instructions:Use range() in for loop to print the numbers.Function range() has here argument...

Q: Create a program that will input the 3 game scores of a player and then output the level of the play...

A: Since there are no messages given in the question for the condition where the weighted average falls...

Q: Write a method that sums all the numbers in the major diagonal in an n x n matrix of double values u...

A: Note: The below program has been complied and executed in NetBeans IDE 8.2

Q: Knapsack Problem This exercise is due Tuesday, May 14. It has to be turned in on time in order to ge...

A: Instructions for completing the table:Enter 0 where objects and weights are zero.For each row assume...

Q: write a program in c++. You work for a box company, and have been asked to write a program to compar...

A: Click to see the answer

Q: Design a Turing machine that computes the function f (x) = x − 2 if x > 2   = 0 i...

A: Click to see the answer

Q: 5-13) Find the largest n such that n cubed is less than a positive integer entered by the user. Use ...

A: The heart of the algorithm lies in finding such a number whose cube is less than the given number he...

Q: • Write a program in Eclipse that computes future investment value at a given interest rate for a sp...

A: Program plan:Import necessary packages.Define a class named “Investment”.Define a method named “comp...

Q: The symmetric difference of two sets S1 and S2 is defined as S1 ⊝ S2 = {x : x ∈ S1 or x ∈ S2, but x ...

A: Solution:Given that,The symmetric difference between two sets such as “S1” and “S2” can be expressed...

Q: Register A holds the 8-bit binary 11011001. Determine the B operand and the logic microoperation to ...

A: Selective Complement: this operations complement the bits in register A for which the corresponding ...

Q: Consider a 32-bit hexadecimal number stored in memory as follows: Address Value 100 2A 101 ...

A: Big-endian:Big-endian is defined as the order in which the most significant value in the sequence is...

Q: use java Develop a program which allows the user to enter numbers into an array. Input will be as fo...

A: To develop this program  ,first of all you import  java.util.Scanner package in  which Scanner class...

Q: Transform the grammar S → aSaaA|A, A → abA|bb into Chomsky normal form.

A:  For solving your problem , first of all we will discuss about  algorithm to convert grammar into  C...

Q: 2. What happens when you give the following commands if the file named done already exists?$ cp to_d...

A: The given two commands cp and mv are used in Linux and Unix. These commands are used for copying and...

Q: 5-18) (Display four patterns using loops) Ask the user to enter an integer toset a limit for nested ...

A: The algorithm would run into 4 sections for each pattern. For patterns A and C each line will have i...

Q: I am trying to write a program to convert an integer to a hexadecimal. How do I do this without us...

A: As there is no particular programming language mentioned, we are doing this conversion of integer nu...