Question: Write a program in Python that computes and display the maximum, minimum, mean (or average), median, and mode of the numeric performance ratings (integers on

Write a program in Python that computes and display the maximum, minimum, mean (or average), median, and mode of the numeric performance ratings (integers on a scale of 0-100) of a group of employees. The data set is to be obtained from a text file (P1HW7.txt) in which each row contains one data point (after all other personally identifying information has been stripped.) The program should terminate with an error message in case of invalid data. Note that the median is the middle number in a sorted list of numbers. If there are two numbers in the middle, compute the median as the average of the two numbers. The mode is the number that occurs with maximum frequency. You may use built-in functions.

Here is what is in the P1HW7.txt file:

36 19 25 53 92 29 74 73 31 40 18 72 56 53 78 59 21 23 81 92 36 46 90 35 83 37 44 66 24 40 84 68 51 82 74 42 47 40 54 66 34 41 73 20 60 80 41 57 82 43 41 29 20 54 86 51 23 63 52 36 72 54 65 30 70 92 72 87 57 25 93 87 24 77 60 74 62 47 45 46 48 54 90 12 46 35 68 89 84 73 35 72 45 28 81 86 67 53 60 68 89 65 67 56 22 60 65 70 84 64 71 91 39 67 31 31 79 13 32 68 43 49 32 13 12 49 76 26 92 75 61 52 19 14 22 48 63 16 50 44 84 90 84 27 53 73 35 47 67 87 41 66 79 31 41 71 54 27 45 42 60 89 58 12 58 76 42 87 66 36 40 34 55 56 36 22 20 65 74 67 52 31 13 25 22 38 61 62 27 27 73 12 57 39 49 87 61 92 42 37 21 78 77 12 35 20 87 52 82 51 67 92 29 92 29 36 42 82 84 89 74 45 92 55 53 52 59 58 28 38 61 27 27 65 69 89 76 28 12 86 44 36 24 48 50 89 89 67 68 63 39 87 66 72 78 93 41 65 65 63 33 23 32 34 23 26 51 93 12 68 18 93 56 81 70 83 63 15 54 84 33 80 81 50 89 21 14 71 64 50 84 90 74 39 88 63 35 48 66 36 66 43 40 41 82 70 52 91 69 75 65 76 54 72 35 30 16 67 61 86 49 79 22 20 29 14 31 29 28 80 42 73 59 30 31 51 18 40 85 49 79 79 43 22 88 40 54 90 57 32 14 29 50 74 34 53 86 23 33 26 89 26 23 80 40 88 93 50 74 85 91 73 29 37 23 74 65 70 37 70 52 25 79 61 24 74 20 48 35 65 21 72 33 48 49 16 12 33 91 24 18 72 68 76 60 93 20 26 33 42 71 81 58 93 76 66 20 17 38 22 20 20 14 87 56 17 92 19 70 15 58 74 77 87 38 93 61 92 54 90 70 29

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!