Home / Expert Answers / Computer Science / python-please-part-2-simplified-gpa-calculator-6-points-complete-the-function-compute-gpa-which-pa364

(Solved): python please Part 2: Simplified GPA Calculator (6 points) Complete the function compute_gpa, which ...



python pleasePart 2: Simplified GPA Calculator (6 points)
Complete the function compute_gpa, which computes and returns a students grade

Part 2: Simplified GPA Calculator (6 points) Complete the function compute_gpa, which computes and returns a student's grade point average. The function takes a single argument, grades, which is a list of strings consisting only of the letters A, B and C. Recall that an A is worth 4 grade points, \( B \) is worth 3 , and \( \mathrm{C} \) is worth 2. Assume that no other grades are present in the list and that every course is worth the same number of credits. Note: loops are not needed to solve this problem!


We have an Answer from Expert

View Expert Answer

Expert Answer


Explanation Loop over the grades Assign gpa is 0 #if grade is A then compute gpa as 4 if grade=="A": gpa=gpa+4 #if grade is B, worth is 3 elif grade==
We have an Answer from Expert

Buy This Answer $5

Place Order

We Provide Services Across The Globe

A PHP Error was encountered

Severity: Notice

Message: fwrite(): write of 34 bytes failed with errno=28 No space left on device

Filename: drivers/Session_files_driver.php

Line Number: 267

Backtrace:

A PHP Error was encountered

Severity: Warning

Message: session_write_close(): Failed to write session data using user defined save handler. (session.save_path: /home/solutionspile.com/public_html/system/sessions)

Filename: Unknown

Line Number: 0

Backtrace: