2023 There are 6 employees Write a program with nested loops to ask the yearly salary of each | Assignment Collections

Computer Science 2023 Cloud9 Computer Science

2023 There are 6 employees Write a program with nested loops to ask the yearly salary of each | Assignment Collections

 

There are 6 employees. Write a program with nested loops, to ask the yearly salary of each employee for 5 years.  Your program should keep track of the highest salary, lowest salary, and  calculate the average salary  of each employee. After you collect each employees data, display the highest salary, lowest salary, and   average salary for that employee. 

Hints: The outer loop is used to keep track of employees, and the inner loop is used to keep track of years for each employee of the outer loop. 

In the test case below, please note that the employee count and year count keeps changing for input message and output messages

You can accomplish this by using an input and print statement like:

salary=input(“Please enter employee “+ str(empcount) +” salary for year ” + str( yearcount) + “: “)

print(“Employee ” + str(empcount) + ” smallest salary is: $”+str(smallest) )

To calculate the average with decimal point, you can use statement like below. 

avg=float(totalsal)/5

The above nstructions are examples. Of course, you must replace the variables with the variables used in your program.

the output has to be like this example

Please enter employee 1 salary for year 1: 45000
Please enter employee 1 salary for year 2: 66000
Please enter employee 1 salary for year 3: 23000
Please enter employee 1 salary for year 4: 54333
Please enter employee 1 salary for year 5: 88000
Employee 1 smallest salary is: $23000
Employee 1 highest salary is: $88000
Employee 1 average salary is: $55266.6
**********
Please enter employee 2 salary for year 1: 34000
Please enter employee 2 salary for year 2: 23000
Please enter employee 2 salary for year 3: 77000
Please enter employee 2 salary for year 4: 24000
Please enter employee 2 salary for year 5: 12000
Employee 2 smallest salary is: $12000
Employee 2 highest salary is: $77000
Employee 2 average salary is: $34000.0
**********
Please enter employee 3 salary for year 1: 34600
Please enter employee 3 salary for year 2: 65000
Please enter employee 3 salary for year 3: 54000
Please enter employee 3 salary for year 4: 99000
Please enter employee 3 salary for year 5: 23000
Employee 3 smallest salary is: $23000
Employee 3 highest salary is: $99000
Employee 3 average salary is: $55120.0
**********
Please enter employee 4 salary for year 1: 88000
Please enter employee 4 salary for year 2: 56000
Please enter employee 4 salary for year 3: 55000
Please enter employee 4 salary for year 4: 45557
Please enter employee 4 salary for year 5: 64000
Employee 4 smallest salary is: $45557
Employee 4 highest salary is: $88000
Employee 4 average salary is: $61711.4
**********
Please enter employee 5 salary for year 1: 56000
Please enter employee 5 salary for year 2: 89777
Please enter employee 5 salary for year 3: 67555
Please enter employee 5 salary for year 4: 45777
Please enter employee 5 salary for year 5: 87555
Employee 5 smallest salary is: $45777
Employee 5 highest salary is: $89777
Employee 5 average salary is: $69332.8
**********
Please enter employee 6 salary for year 1: 77666
Please enter employee 6 salary for year 2: 88777
Please enter employee 6 salary for year 3: 66555
Please enter employee 6 salary for year 4: 44555
Please enter employee 6 salary for year 5: 88999
Employee 6 smallest salary is: $44555
Employee 6 highest salary is: $88999
Employee 6 average salary is: $73310.4
********** 

 

We give our students 100% satisfaction with their assignments, which is one of the most important reasons students prefer us to other helpers. Our professional group and planners have more than ten years of rich experience. The only reason is that we have successfully helped more than 100000 students with their assignments on our inception days. Our expert group has more than 2200 professionals in different topics, and that is not all; we get more than 300 jobs every day more than 90% of the assignment get the conversion for payment.

Place Order Now

#write essay #research paper #blog writing #article writing #academic writer #reflective paper #essay pro #types of essays #write my essay #reflective essay #paper writer #essay writing service #essay writer free #essay helper #write my paper #assignment writer #write my essay for me #write an essay for me #uk essay #thesis writer #dissertation writing services #writing a research paper #academic essay #dissertation help #easy essay #do my essay #paper writing service #buy essay #essay writing help #essay service #dissertation writing #online essay writer #write my paper for me #types of essay writing #essay writing website #write my essay for free #reflective report #type my essay #thesis writing services #write paper for me #research paper writing service #essay paper #professional essay writers #write my essay online #essay help online #write my research paper #dissertation writing help #websites that write papers for you for free #write my essay for me cheap #pay someone to write my paper #pay someone to write my research paper #Essaywriting #Academicwriting #Assignmenthelp #Nursingassignment #Nursinghomework #Psychologyassignment #Physicsassignment #Philosophyassignment #Religionassignment #History #Writing #writingtips #Students #universityassignment #onlinewriting #savvyessaywriters #onlineprowriters #assignmentcollection #excelsiorwriters #writinghub #study #exclusivewritings #myassignmentgeek #expertwriters #art #transcription #grammer #college #highschool #StudentsHelpingStudents #studentshirt #StudentShoe #StudentShoes #studentshoponline #studentshopping #studentshouse #StudentShoutout #studentshowcase2017 #StudentsHub #studentsieuczy #StudentsIn #studentsinberlin #studentsinbusiness #StudentsInDubai #studentsininternational