Question: First, create a project named HW 1 ; Second, create a module named Grade . In this module, you need to define two
First, create a project named HW;
Second, create a module named "Grade" In this module, you need to define two functions:
calcaverage: this function receives a list of scores, then calculates the average of scores in this function and return the average.
converter : this function receives a score, verifies it is a valid grade ~ first, and then coverts the score into a letter grade based on the criteria in the following table and returns the letter grade.
PGrade.jpg
Third, create another module named "GradeTester". This module will import the Grade module. Tester will test the functions defined in Grade module. To test the functions, it will ask users dynamically enter grades and then pass the grades to the Grade.calcaverage then call Grade. converter to convert the average grade into a letter grade and display it on screen. When finish oneround testing, the Tester allows users to continue to test more grades. Attach your testing runs data to the Tester module and save the data.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
