Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

A company pays its employees as managers (who receive a fixed weekly salary), hourly workers (who receive a fixed hourly wage for up to the

image text in transcribed
A company pays its employees as managers (who receive a fixed weekly salary), hourly workers (who receive a fixed hourly wage for up to the first 40 hours they work and time-and-a-half-le. 1.5 times their hourly wage--for overtime hours worked). commission workers (who receive 5250 plus 5.7% of their gross weekly sales), or pieceworkers (who receive a fixed amount of money for each of the items they produce-each pieceworker in this company works on only one type of item). Write a program to compute the weekly pay for each employee. You do not know the number of employees in advance. Each type of employee has its own pay code: Managers have paycode 1, hourly workers have code 2. commission workers have code 3 and pleceworkers have code 4. Use a switch to compute each employee's pay based on that employee's paycode. Within the switch, prompt the user (i.e. the payroll clerk) to enter the appropriate facts your program needs to calculate each employee's pay based on that employee's paycode. The program should run continuously until the user terminates it. An example of ouput is as follows: User Instructions Managers paycode '1' Hourly Workers paycode '2' Comission Worker paycode 3 Pieceworkers paycode 4 paycode = 'o' to terminate the program. Enter paycode=1 Enter fixed weekly salary of manager=350 Weekly Salary = 350.00 Enter paycode=3 Enter Commission Worker Gross Weekly Sales=300 Weekly Salary = 267.10 Enter paycode=4 Enter Number of Items Produced=95 Enter Fixed Amount per Item=2.2 Weekly Salary = 209.00 Enter paycode=0 Program is terminated by the user. Submit Pseudo Code . C code with detailed comments Implement secure C and best programming practices

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Microsoft Visual Basic 2017 For Windows Web And Database Applications

Authors: Corinne Hoisington

1st Edition

1337102113, 978-1337102117

More Books

Students also viewed these Databases questions

Question

Name the following compounds.

Answered: 1 week ago

Question

Outline key considerations when making a hiring decision.

Answered: 1 week ago