00:01
Okay, so this one says average score.
00:03
Write a program that uses four loops to calculate data, to collect data and calculate the average score on a number of tests for a number of students.
00:19
Program should one.
00:20
First ask the user to enter the number of students in a range 1 to 10.
00:26
We can do that.
00:28
So n, let's say, is we'll make it a float.
00:32
I'm sorry, we'll make it an input.
00:35
Please enter the number of students from 1 to 10.
00:40
Okay then the program asks the user to enter the number of tests.
00:45
Okay we can do that too.
00:47
I also call this n -s for n students and t for n tests let's say please enter the number of tests.
00:58
Use a loop to collect the scores for those many tests for each student so we have to make an outer loop that loops over the students so let's say for s in range lena or in range at s and for t in range and t and we have to collect the scores so presumably we have to ask for them again or ask for the scores we'll say score equals float input input score for student s plus one test test so let's just see what happens for else.
02:12
We say 1 1.
02:14
Please enter the score for student 1 test 1 100.
02:17
The score is 100.
02:22
For all iterations, program should calculate and display total scores for an average score for each student.
02:29
Okay, so let's say for i in range.
02:34
For iron range yes so okay obviously we need to append these to a list let's say student scores this and we'll say test scores this and then here we're going to append scores and then score here we're going to say student student score depend scores so so i think they have an empty four loop here.
03:15
Next we're going to loop through these student scores.
03:17
So student score.
03:20
And we want us to print out their average.
03:22
So let's do, let's use numpy for this...