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
Galina-37 [17]
2 years ago
10

a) At a particular company, employees are rated at the end of each year. The rating scale begins at 0.0, with higher values indi

cating better performance and resulting in larger raises. The value awarded to an employee is either 0.0, 0.4, or 0.6 or more. Values between 0.0 and 0.4, and between 0.4 and 0.6 are never used. The meaning associated with each rating is shown in the following table. The amount of an employee’s raise is $2400.00 multiplied by their rating. Write a program that reads a rating from the user and indicates whether the performance was unacceptable, acceptable or meritorious. The amount of the employee’s raise should also be reported. Your program should display an appropriate error message if an invalid rating is entered. code in python programming
Engineering
1 answer:
ELEN [110]2 years ago
4 0

The program that can display an appropriate error message if an invalid rating is illustrated below.

<h3>How to illustrate the program?</h3>

The program for the error message will be:

CONSTANTS

RAISE_FACTOR = 2400.00

UNACCEPTABLE = 0.0

ACCEPTABLE = 0.4

MERITORIOUS = 0.6

# input of user rating

rating = float(input('Enter your rating: '))

# based on rating display the performance and salary raise

if rating == UNACCEPTABLE:

print('Your performance was UNACCEPTABLE. Raise in salary: $%.2f' %(RAISE_FACTOR*UNACCEPTABLE))

elif rating == ACCEPTABLE:

print('Your performance was ACCEPTABLE. Raise in salary: $%.2f' %(RAISE_FACTOR*ACCEPTABLE))

elif rating == MERITORIOUS:

print('Your performance was MERITORIOUS. Raise in salary: $%.2f' %(RAISE_FACTOR*MERITORIOUS))

else: # invalid rating

print('Invalid Rating. Valid ratings are 0.0, 0.4 and 0.6')

Learn more about program on:

brainly.com/question/1786465

#SPJ1

You might be interested in
Water flows through a horizontal plastic pipe with a diameter of 0.15 m at a velocity of 15 cm/s. Determine the pressure drop pe
Sonja [21]

Answer:0.1898 Pa/m

Explanation:

Given data

Diameter of Pipe\left ( D\right )=0.15m

Velocity of water in pipe\left ( V\right )=15cm/s

We know viscosity of water is\left (\mu\right )=8.90\times10^{-4}pa-s

Pressure drop is given by hagen poiseuille equation

\Delta P=\frac{128\mu \L Q}{\pi D^4}

We have asked pressure Drop per unit length i.e.

\frac{\Delta P}{L} =\frac{128\mu \ Q}{\pi D^4}

Substituting Values

\frac{\Delta P}{L}=\frac{128\times8.90\times10^{-4}\times\pi \times\left ( 0.15^{3}\right )}{\pi\times 4 \times\left ( 0.15^{2}\right )}

\frac{\Delta P}{L}=0.1898 Pa/m

4 0
3 years ago
Write a program that uses a function called Output_Array_Info. Output_Array_Info Properties: Input Parameters: 1. A pointer to a
Artyom0805 [142]

Answer:

C++ code explained below

Explanation:

Please note the below program has been tested on ubuntu 16.04 system and compiled using g++ compiler. This code will also work on other IDE's

-----------------------------------------------------------------------------------------------------------------------------------

Program:

-----------------------------------------------------------------------------------------------------------------------------------

//header files

#include<iostream>

//namespace

using namespace std;

//function defintion

void Output_Array_Info(int *array_ptr, int size)

{

//display all array elements

cout<<"Array elements are: "<<endl;

for(int i =0; i<size; i++)

{

cout<<*(array_ptr+i)<<endl;

}

//display address of each element

cout<<endl<<"memory address of each array elemnt is: "<<endl;

for(int i =0; i<size; i++)

{

cout<<array_ptr+i<<endl;

}

}

//start of main function

int main()

{

//pointer variables

int *pointer;

//an array

int numbers[] = { 5, 7, 9, 10, 12};

//pointer pointing to array

pointer = numbers;

//calculate the size of the array

int size = sizeof(numbers)/sizeof(int);

//call to function

Output_Array_Info(numbers, size);

return 0;

}

//end of the main program

8 0
3 years ago
In a website browser address bar, what does “www” stand for?
Ludmilka [50]

Answer:

www stands for world wide web

Explanation:

It will really help you thank you.

3 0
3 years ago
Consider laminar, fully developed flow in a channel of constant surface temperature Ts. For a given mass flow rate and channel l
Pachacha [2.7K]

Answer:

Please see attachment.

Explanation:

8 0
3 years ago
Consider the following ways of handling deadlock: (1) banker’s algorithm, (2) detect
Andrew [12]

Answer:

b

Explanation:

7 0
3 years ago
Other questions:
  • If a torque of M = 300 N⋅m is applied to the flywheel, determine the force that must be developed in the hydraulic cylinder CD t
    13·1 answer
  • List four reasons why we need aceuracy in machined parts.
    8·1 answer
  • What is the magnitude of the maximum stress that exists at the tip of an internal crack having a radius of curvature of 2.5×10-4
    13·1 answer
  • Explain why change is inevitable in complex systems and give examples (apart from prototyping and incremental delivery) of softw
    6·1 answer
  • We need to design a logic circuit for interchanging two logic signals. The system has three inputs I1I1, I2I2, and SS as well as
    11·1 answer
  • Water discharging into a 10-m-wide rectangular horizontal channel from a sluice gate is observed to have undergone a hydraulic j
    12·1 answer
  • Hi im ***ar and im doing sculptural but what should it be about star wars or Marvel
    9·1 answer
  • Which of the following sentences uses the word malleable correctly?
    7·2 answers
  • Write a Nested While Loop that will increment the '*' from 1 to 10.
    6·1 answer
  • What is the first step of the engineering design process?
    9·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!