Question: Objective of this homework assignment is to practice functions, lists and files. Problem Description: program generates a list 'Marks' with 3 0 data elements which

Objective of this homework assignment is to practice functions, lists and files.
Problem Description: program generates a list 'Marks' with 30 data elements which is filled with the random numbers between 40 and 99. Then each of these grades categorized as follows in the list Grades:
\table[[Marks,Grade],[Above and equal to 85,A],[Above and equal to 75,B],[Above and equal to 60,C],[Above and equal to 50,D],[Otherwise,F]]
Display the marks and grade in the tabular format with three columns in a file called 'output.txt'.
Your program should consist of main() and all other functions are called by main().
ReadMarks(): Generates the list Marks filled with numbers between 40 and 99 and returns the list to the main()
determineGrades(...): it receives the Marks list and generate a new list called Grades as per above table.
PrintResults(.....): receives the marks and grades list.
Prints the marks and grades in the tabular format and then prints the lowest marks for each grade A, B, C, D.
Sample Output:
\table[[,,,,,,],[hw4.py ,Output.txt ,A],[1,82,B,63,C,98],[2,69,C,88,A,98,A],[3,80,B,54,D,88,A],[4,93,A,81,B,44,F
 Objective of this homework assignment is to practice functions, lists and

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!