Pseudocode for hours worked
WebImplement function wage () that takes two arguments: an hourly wage and the number of hours an employee worked in the last week. Your function should compute and return the employee’s pay. Any hours worked beyond 40 is overtime and should be paid at 1.5 times the regular hourly wage. WebThen they would earn $30/hr for the 20 hours they worked overtime. Therefore, they earned: ($20/hr * 40hrs) + ($30/hr * 20 hrs) = $800 + $600 = $1400 total. For this assignment, you must create pseudocode and a flowchart to design a program that will calculate an employee’s weekly paycheck.
Pseudocode for hours worked
Did you know?
WebView Module 3 pseudocode.docx from IT-140 J2547 at Southern New Hampshire University. Module 3 pseudocode GET employee hours worked IF employee hours are greater than 0 IF employee hours are less WebPseudocode: Input employee’s weekly hours Input employee’s rate per hour. IF the total hours are 40 and less, the hourly rate is $20. CALCULATE hourly rate and hours worked. …
WebThe Required pseudocode is provided below: Step1: Declare two float variables: workHours and payCheck Step 2: Print “Enter the number of work hours” Step 3: Read the user input into variable workHours Step 4: Insert an IF-ELSE block as illustrated below: IF (workHours<0) PRINT “Invalid input” EXIT ELSE IF (workHours<=40) WebJul 26, 2024 · Here are the steps you can follow to solving programming problems with pseudocode: Step 1: Understand what the function does First, you need to understand that all a function does is (optionally) accept data as input, work on the data little by little, and finally return an output.
WebAug 18, 2015 · Write pseudocode to represent the logic of a program that allows a user to enter two values then outputs the product of the two values I wrote: start input takeOne input takeTwo output takeONe, takeTwo Stop Or Start Declarations ouPutTwo = takeOne, takeTwo Input takeOne, takeTwo Output ouPutTwo Stop Is this right? should I go like this? Webone line of pseudocode. EX: TASK LIST: Read name, hourly rate, hours worked, deduction rate Perform calculations gross = hourlyRate * hoursWorked deduction = grossPay * …
WebSep 5, 2024 · Pseudo code: 1. declare a variable "hour_worked". 1.1 read the hours worked in a day by user and assign it to "hour_worked". 2.Calculate total work in a five-day week as "Week_work=5*hour_worked". 3.Calculate total work in a 252-day year as "year_work=252*hour_worked". 4. print the value of "Week_work" and "year_work". 5.End …
WebGabriel Primus August 1, 2024 3-3 Assignment: Introduction to Pseudocode and Flowcharts. Problem: A company wants a program that will calculate the weekly paycheck for an employee based on how many hours they worked. For this company, an employee earns $20 an hour for the first 40 hours that they work. john okello hero of africaWebNov 20, 2024 · The pseudocode will look something like this: Function calculate paycheck Input: hours Ouput: paycheck amount IF hours is greater than 40 THEN regular hours = 40 overtime hours = hours - 40 RETURN (regular hours x 20) + (overtime hours x 30) ELSE RETURN (hours x 20) Upvote • 0 Downvote Add comment Report Still looking for help? how to get stretched resolution on amdWebAs for the pseudo-code, you could break it into two lines/calculations pay = / overtime = and then add them together, you could break out hours and overtime hours, and/or add … how to get stretched res on csgo amdjohn oldfield \u0026 alice rogersWebThe following is the required Pseudo code that gives the outputs of working hour in five-day week and the hours worked in 252 days work year. start. Declarations. num hours. num … john olander chief operating officerWebExample 7 Pseudocode: Input the employee name, employee overtime hours, and employee absent hours (Name, Overtime, Absent) Calculate net bonus hours net_bonus_hours=Overtime-(2/3)*Absent Get the bonus from the table according to the next bonus hours Print employee name and his bonus paid john oldfield obituaryWebThe pay for any hours worked as overtime is paid 1.5 times the hourly rate. Write a pseudocode and draw a flowchart that computes for the pay of an employee and display it given the hourly rate and the specific number of hours worked of the employee in a week. john oldfield york pa