Question

IN PYTHON ONLY !! Program 2: Re-work program #5 (WeeklyHours) from the previous assignment such that...

IN PYTHON ONLY !! Program 2: Re-work program #5 (WeeklyHours) from the previous assignment such that

1. The program prints out the day an employee worked most hours.

2. The program outputs are displayed in ascending order (stored) by Weekly Hours. Notice that we modifying method addHours()to display the outputs sorted by total weekly hours for each employee as shown below.

Sample run 1:

Employees Data:

           Mon Tue Wed Thu Fri Sat Sun

Employee1   5    3    2    9    6    5    7

Employee2   7    6   8    5    5    4    5

Employee3   1    2    2    1    5    8    7

Employee1 worked most hours on Thursday

Employee2 worked most hours on Wednesday

Employee3 worked most hours on Saturday

Employee# Weekly Hours

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

   3            26

   1            37

   2            40

Sample run 2:

Employees Data:

           Mon Tue Wed Thu Fri Sat Sun

Employee1   10   2    7    2    0    3    8

Employee2   5    6    1    5    1    4    2

Employee3   1    5    2    6    4    8    7

Employee1 worked most hours on Monday

Employee2 worked most hours on Tuesday

Employee3 worked most hours on Saturday

Employee# Weekly Hours

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

   2            24

   1            32

   3            33

0 0
Add a comment Improve this question Transcribed image text
Know the answer?
Add Answer to:
IN PYTHON ONLY !! Program 2: Re-work program #5 (WeeklyHours) from the previous assignment such that...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • IN PYTHON the original problem was Design (pseudocode) and implement (source code) a program (name it...

    IN PYTHON the original problem was Design (pseudocode) and implement (source code) a program (name it WeeklyHours) to compute the total weekly hours for 3 employees. The program main method defines a two-dimensional array of size 3x7 to store employers’ daily hours for the week. Each row represents one employee and each column represent one day of the week such that column 0 designates Monday, column 1 designates Tuesday, etc. The program main method populates the array with random numbers...

  • Program 5: Design (pseudocode) and implement (source code) a program (name it Weekl yHours) to compute...

    Program 5: Design (pseudocode) and implement (source code) a program (name it Weekl yHours) to compute the total weekly hours for 3 employees. The program main method defines a two-dimensional array of size 3x7 to store employers' daily hours for the week. Each row represents one employee and each column represent one day of the week such that column 0 designates Monday, column 1 designates Tuesday, etc. The program main method populates the array with random numbers between 0 and...

  • A local franchise of a national chain of day-old pastry stores recorded the number of customers that came in to the store for five weeks this fall. The national franchisor states that the percentage o...

    A local franchise of a national chain of day-old pastry stores recorded the number of customers that came in to the store for five weeks this fall. The national franchisor states that the percentage of customers is distributed as follows: Sunday – 20%, Monday – 8%, Tuesday – 6%, Wednesday – 7%, Thursday – 12%, Friday – 22%, Saturday – 25%. The manager doesn’t trust the franchisor and wants to show his store has different percentages. Use a χ² Goodness-of-Fit...

  • A local franchise of a national chain of day-old pastry stores recorded the number of customers that came in to the store for five weeks this fall. These data are recorded in the attached file. The na...

    A local franchise of a national chain of day-old pastry stores recorded the number of customers that came in to the store for five weeks this fall. These data are recorded in the attached file. The national franchisor states that the percentage of customers is distributed as follows:   Sunday – 20%, Monday – 8%, Tuesday – 6%, Wednesday – 7%, Thursday – 12%, Friday – 22%, and Saturday – 25%. The manager doesn’t trust the franchisor and wants to show...

  • Code in PYTHON I have a small company. I need a payroll system that calculates the...

    Code in PYTHON I have a small company. I need a payroll system that calculates the pay and taxes for each employee. I have the following input files: • EmployeeData ENum,ELName,EFName,Work Area,HrlyRate 1101,Davis,Mike,7,24.85 1385,Smith,William,1,19.50 1524,White,James,3,23.50 1998,Stuart,Mary,1,25.00 2358,Scott,Richard,4,20.00 2765,Mills,Jason,5,21.00 2945,Schultz,Cindy,7,23.50 4789,Moffett,William,3,30.00 5304,Rangel,Ken,2,28.00 5521,Rodriguez,Teresa,4,29.00 6447,Butler,Craig,2,18.50 6512,Russell,Don,6,26.00 6614,Wilson,Keith,1,28.50 6749,Johnson,Darrell,6,32.00 7325,Butler,Eileen,4,17.00 7886,Williams,Gina,1,21.00 8356,Roberts,Judy,8,23.00 8466,Soto,Glen,8,22.50 9458,Cooper,Lia,4,26.50 9896,Bonds,Lisa,5,27.00 • TaxTable LRange,URange,TaxAmt 0.01,200.00,20.00 200.01,400.00,50.00 400.01,600.00,75.00 600.01,800.00,100.00 800.01,1000.00,120.00 1000.01,1200.00,150.00 1200.01,1400.00,180.00 1400.01,1600.00,220.00 1600.01,1800.00,250.00 1800.01,2000.00,300.00 2000.01,2200.00,325.00 2200.01,2500.00,350.00 starting at zero and ending at 2,500.00. • TimeCardData ENum,Day,DailyHours 1101,FRI,8.00 1101,MON,8.00 1101,THU,8.00...

  • Work Scheduling: Burger Queen would like to determine the min # of kitchen employees. Each employ...

    Work Scheduling: Burger Queen would like to determine the min # of kitchen employees. Each employee works six days a week and takes the seventh day off. Days Mon Tue Wed Thu Fri Sat Sun Min. # of workers 6 9 How do yu forulaic: ihis problem The objective function? The constraints? Work Scheduling: Burger Queen would like to determine the min # of kitchen employees. Each employee works six days a week and takes the seventh day off. Days...

  • Will give positive rating! AM/PM Method Assignment # 03: Calculate the early and late dates for the following activiti...

    Will give positive rating! AM/PM Method Assignment # 03: Calculate the early and late dates for the following activities, and create a bar chart. Assuming a Monday to Friday working week and the first activity starting on Dec 01 20XX. 1-Dec Activity A Activity B Activi Activity F Activity G 2 days da 3 da da 2 da Activity C Activity E 3 da 3 da SUNDAY MONDAY TUESDAY WEDNESDAY THURSDAY FRIDAY SATURDAY 2 4 Fulil Mocn NW 10 12...

  • Write a C# program that prints a calendar for a given year. Call this program calendar....

    Write a C# program that prints a calendar for a given year. Call this program calendar. The program prompts the user for two inputs:       1) The year for which you are generating the calendar.       2) The day of the week that January first is on, you will use the following notation to set the day of the week:             0 Sunday                     1 Monday                   2 Tuesday                   3 Wednesday       4 Thursday                 5 Friday                      6 Saturday Your program should...

  • #2 A For the full Heaven! Chocolates data set, fill in the correlation table (to two...

    #2 A For the full Heaven! Chocolates data set, fill in the correlation table (to two decimals) Time Pages Amt Spent Time Pages Amt Spent #2.B which variables, if any, are correlated under the 0.7 rule? #3.A Fill in the mean values of Time and Amt Spent by day of the week (to two decimals): Time Amt Spent Sun Mon Tue Wed Thu ! Fri Sat 6.50 #3.8 The greatest mean value of Time, which is a demand on the...

  • Write a C# program that prints a calendar for a given year. Call this program calendar....

    Write a C# program that prints a calendar for a given year. Call this program calendar. This program needs to use Switch Case in order to call the methods and format to print each month. The program prompts the user for two inputs:       1) The year for which you are generating the calendar.       2) The day of the week that January first is on, you will use the following notation to set the day of the week:      ...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT