Can you help me with this by writing these three questions as c programming?

Question 01

A mobile manufacturing company pays its employees as follows:

1) Team leaders (fixed fortnightly salary)

2) Sales workers ($500 plus 6.5% of their gross fortnightly sales)

3) Pieceworkers (fixed amount of money per item for each of the items they produce, each piece worker in this company works on only 1 type of item)

4) Hourly workers (fixed hourly wage for up to the first 60 hours they work and -time-and a-half- i.e. 1.5 times their hourly wage, for overtime hours worked)

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:

Code 1: Team leaders

Code 2: Sales workers

Code 3: Pieceworkers

Code 4: Hourly workers

There will be an undetermined number of entries into the payroll. Use a switch to compute each employees pay based on that employees pay code. Within the switch, prompt the user (i.e. the payroll clerk) to enter the appropriate facts your program needs to calculate each employees pay based on that employees pay code. Print each pay value and when done with the entries, print total amount of payroll.

Sample Run:

Enter employee’s number code (-1 to end): 4

Enter hourly worker’s pay rate: 10

Enter the number of hours worked: 35 fortnightly pay is: 350.00

Enter employee’s number code (-1 to end): 4

Enter hourly worker’s pay rate: 15.5

Enter the number of hours worked: 100 fortnightly pay is: 1860

Enter employee’s number code (-1 to end): 4

Enter hourly worker’s pay rate: 10

Enter the number of hours worked: 40 fortnightly pay is: 400.00

Enter employee’s number code (-1 to end): 1

Enter the Team leaderss pay rate: 576.90 fortnightly pay is: 576.90

Enter employee’s number code (-1 to end): 2

Enter Sales employee’s gross weekly sales:

1091.45 fortnightly pay is: 570.94

Enter employee’s number code (-1 to end): 3

Enter the number of pieces completed: 200 Enter the employee’s per piece pay rate: 0.5 fortnightly pay is: 100

Enter employee’s number code (-1 to end): 8 You have entered an invalid code.

Enter employee’s number code (-1 to end): 9 You have entered an invalid code.

Enter employee’s number code (-1 to end): 3

Enter the number of pieces completed: 100 Enter the employee’s per piece pay rate: 2.75 fortnightly pay is: 275.00

Enter employee’s number code (-1 to end): -1

The total payroll for the fortnight is:4132.84

Question 02

Use the rand function to produce two positive one-digit integers (0 includes). The program should then prompt the user with a question, such as How much is 2 + 3?

The user then inputs the answer (Enter -1 to stop). Next, the program checks the users answer. If its correct, the program should randomly display any of the following messages

1. Very good!

2. Excellent!

3. Nice work!

4. Keep up the good work!

and ask another addition question.

If the answer is wrong, randomly display any of the following messages.

1. No. Please try again.

2. Wrong. Try once more.

3. Dont give up!

4. No. Keep trying and let the user try the same question repeatedly until the user finally gets it right.

A separate function should be used to generate each new question. This function should be called once when the application begins execution and each time the user answers the question correctly.

(Hint: Use random-number generation to choose a number from 1 to 4 that will be used to select one of the four appropriate responses to each correct or incorrect answer. Use a switch statement to issue the responses.)

Question 03

Consider a sequence of floating point numbers, x,,i = 1,2, m. The mean is defined as: x = (xj +x2+»—,+xm)/m

the deviation about the mean is

d, = x, - x / = 1,2, ..., m

and the standard deviation is

s = yj(df + +.•••,+)/(m-1)

Write a complete C program to do the following tasks:

(!) Read a positive integer from user as the value of m (need to verify that m is positive but less than 30).

(ii) Read in the m elements (up to 30) of a one-dimensional floating point array, compute the sum of these elements, the mean, the deviation, and the standard deviation.

5 a

Key in a positive integer:32 Urong input, plz try again Key in a positive integer:-l Wrong input, plz try again Key in a positive integer:5 xE0J=1 xEU=2 xE2]=3 xE3]=4 xMJ-5 mean = 3.00

Deviation Ex=1.00J = -2.00 Deviation Ex=2.00] = -1.00 Deviation Ex-3.001 = 0.00 Deviation Ex=4.00] ¦ 1.00 Deviation Ex=5.00] « 2.00

Standard Deviation = 1.58

Question 01

A mobile manufacturing company pays its employees as follows:

1) Team leaders (fixed fortnightly salary)

2) Sales workers ($500 plus 6.5% of their gross fortnightly sales)

3) Pieceworkers (fixed amount of money per item for each of the items they produce, each piece worker in this company works on only 1 type of item)

4) Hourly workers (fixed hourly wage for up to the first 60 hours they work and -time-and a-half- i.e. 1.5 times their hourly wage, for overtime hours worked)

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:

Code 1: Team leaders

Code 2: Sales workers

Code 3: Pieceworkers

Code 4: Hourly workers

There will be an undetermined number of entries into the payroll. Use a switch to compute each employees pay based on that employees pay code. Within the switch, prompt the user (i.e. the payroll clerk) to enter the appropriate facts your program needs to calculate each employees pay based on that employees pay code. Print each pay value and when done with the entries, print total amount of payroll.

Sample Run:

Enter employee’s number code (-1 to end): 4

Enter hourly worker’s pay rate: 10

Enter the number of hours worked: 35 fortnightly pay is: 350.00

Enter employee’s number code (-1 to end): 4

Enter hourly worker’s pay rate: 15.5

Enter the number of hours worked: 100 fortnightly pay is: 1860

Enter employee’s number code (-1 to end): 4

Enter hourly worker’s pay rate: 10

Enter the number of hours worked: 40 fortnightly pay is: 400.00

Enter employee’s number code (-1 to end): 1

Enter the Team leaderss pay rate: 576.90 fortnightly pay is: 576.90

Enter employee’s number code (-1 to end): 2

Enter Sales employee’s gross weekly sales:

1091.45 fortnightly pay is: 570.94

Enter employee’s number code (-1 to end): 3

Enter the number of pieces completed: 200 Enter the employee’s per piece pay rate: 0.5 fortnightly pay is: 100

Enter employee’s number code (-1 to end): 8 You have entered an invalid code.

Enter employee’s number code (-1 to end): 9 You have entered an invalid code.

Enter employee’s number code (-1 to end): 3

Enter the number of pieces completed: 100 Enter the employee’s per piece pay rate: 2.75 fortnightly pay is: 275.00

Enter employee’s number code (-1 to end): -1

The total payroll for the fortnight is:4132.84

Question 02

Use the rand function to produce two positive one-digit integers (0 includes). The program should then prompt the user with a question, such as How much is 2 + 3?

The user then inputs the answer (Enter -1 to stop). Next, the program checks the users answer. If its correct, the program should randomly display any of the following messages

1. Very good!

2. Excellent!

3. Nice work!

4. Keep up the good work!

and ask another addition question.

If the answer is wrong, randomly display any of the following messages.

1. No. Please try again.

2. Wrong. Try once more.

3. Dont give up!

4. No. Keep trying and let the user try the same question repeatedly until the user finally gets it right.

A separate function should be used to generate each new question. This function should be called once when the application begins execution and each time the user answers the question correctly.

(Hint: Use random-number generation to choose a number from 1 to 4 that will be used to select one of the four appropriate responses to each correct or incorrect answer. Use a switch statement to issue the responses.)

Question 03

Consider a sequence of floating point numbers, x,,i = 1,2, m. The mean is defined as: x = (xj +x2+»—,+xm)/m

the deviation about the mean is

d, = x, - x / = 1,2, ..., m

and the standard deviation is

s = yj(df + +.•••,+)/(m-1)

Write a complete C program to do the following tasks:

(!) Read a positive integer from user as the value of m (need to verify that m is positive but less than 30).

(ii) Read in the m elements (up to 30) of a one-dimensional floating point array, compute the sum of these elements, the mean, the deviation, and the standard deviation.

5 a

Key in a positive integer:32 Urong input, plz try again Key in a positive integer:-l Wrong input, plz try again Key in a positive integer:5 xE0J=1 xEU=2 xE2]=3 xE3]=4 xMJ-5 mean = 3.00

Deviation Ex=1.00J = -2.00 Deviation Ex=2.00] = -1.00 Deviation Ex-3.001 = 0.00 Deviation Ex=4.00] ¦ 1.00 Deviation Ex=5.00] « 2.00

Standard Deviation = 1.58

ASSESSMENT TASK 3 (in two parts)1. Create a piece of work that relates themes from the Book of the Year, This is my Song (for example, racism, persecution, trauma, hope etc.) to the CST principles. This...1200 wordASSESSMENT TASK 3 (in two parts) uncc100 creative task and written reflection; assessment of application skills in relation to LO1 and LO2: following the generation of a creative work, students...SampleASSESSMENT 2 BRIEFSubject Code and Title LAW 6001 Taxation LawAssessment Assessment 2: Case Study (Individual taxpayer’s tax return)Individual/Group IndividualLength For the Report 2000 words +/- 10% excluding...Online Discussion- Press FreedomDue: Thu, Oct 22 2020 at 11:59 PMEnumerate the cases presented by Presidential Spokesperson Harry Roque, UP Journalism Professor- Danilo Arao, and Political Scientist Richard...Task5-ReportThe facilitator to identify a list of Australian businesses headquartered in that campus’s city (in APPENDIX 8). The report is to be written for axis investments, a large international investment...ContentsAssessment information 3Assessment instructions 4Student assessment agreement 7Assessment Task 1 Cover Sheet 8Assessment Task 1: Written questions 9Assessment Task 1 Instructions as provided to...**Show All Questions**