+ 1

I need help

Vaccination report

2nd Sep 2021, 8:25 AM
TroyxHunter
10 Respostas
+ 3
Sum of terms/Number of terms = mean
2nd Sep 2021, 8:29 AM
Rellot's screwdriver
Rellot's screwdriver - avatar
+ 3
#I used mathematics to calculate it. print((0*5+1*8+2*4+3*3)/20)
2nd Sep 2021, 9:42 AM
Simba
Simba - avatar
+ 2
To understand it easily, you can store all the data in a list [0,0,0,0,0,1,1,1.....,2,2,2,2,3,3,3]
2nd Sep 2021, 8:32 AM
Simba
Simba - avatar
+ 1
Never(never is 0) =5people so => [0,0,0,0,0] Once( once is 1)=8 people =>[1,1,1,1,1,1,1,1] twice(twice is 2) =4people =>[2,2,2,2] 3 times(3 times is 3)=3people =>[3,3,3] They all are stored in a variable Like a=[0,0,0,0,0,1,1,1,1,1,1,1,1,2,2,2,2,3,3,3] #use loop to calculate total=0 for i in a: total+=i print(total/len(a)) #for mean value
2nd Sep 2021, 8:54 AM
Myo Thuzar
Myo Thuzar - avatar
0
We have a report on the number of flu vaccinations in a class of 20 people. It has the following numbers: never: 5 once: 8 twice: 4 3 times: 3 What is the mean number of times those people have been vaccinated? Output the result using the print() statement
2nd Sep 2021, 8:25 AM
TroyxHunter
0
U mean 5+8+4+3/4
2nd Sep 2021, 8:32 AM
TroyxHunter
0
(5+8+4+3)/4
2nd Sep 2021, 8:33 AM
TroyxHunter
0
I have not yet got to that stage
2nd Sep 2021, 8:34 AM
TroyxHunter
0
Plus I don't no what that means Simba
2nd Sep 2021, 8:34 AM
TroyxHunter
0
Thanks bro
2nd Sep 2021, 8:56 AM
TroyxHunter