Question: A teacher wants a program to give extra points to students who fail a test. Write a Python program to do the following: Ask the

A teacher wants a program to give extra points to students who fail a test. Write a Python program to do the following:

  1. Ask the user to enter 5 test scores. Store the scores in a list. Display the list.
  2. Copy all 5 test scores to another list. Use a loop to examine each test score in the new list. If the score is below 60, add 10 extra points to the score. Display the list.
  3. Compare the old score and new score of each student. If the old score and new score are different, display the two scores.

    The following output is an example:

    Enter a test score: 45

    Enter a test score: 77

    Enter a test score: 88

    Enter a test score: 52

    Enter a test score: 90

    All scores: [45.0, 77.0, 88.0, 52.0, 90.0]

    Students who scored below 60 get 10 extra points.

    All scores: [55.0, 77.0, 88.0, 62.0, 90.0]

    Students whose scores have changed:

    Old score: 45.0 New score: 55.0

    Old score: 52.0 New score: 62.0

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!