Question: Python Create a function called creditsPerQuarter. It will receive parameters: student, numCreds, numCourses. You will pass in a students name, the number of credits each

Python

  1. Create a function called creditsPerQuarter. It will receive parameters: student, numCreds, numCourses. You will pass in a students name, the number of credits each course they are taking is and the number of courses they are taking. Within the function, you will calculate the total number of credits that student has that quarter. You will RETURN the following string: (student name) is taking (number of courses) courses and each course is (number of credits each course is) for a total of (calculated total credits). For example: If the student is Bob and he is taking 4 courses with 3 credit each it would read exactly: "Bob is taking 4 courses and each course is 3 credits for a total of 12."

You will call creditsPerQuarter three times and pass in these arguments:

  • Student Name: Wade, Credit per Course: 3, Number of courses: 4
  • Student Name: Jane, Credit per Course: 3, Number of courses: 5
  • Student Name: Evan, Credit per Course: 5, Number of courses: 3

Your output should look like this exactly:

Wade is taking 4 courses and each course is 3 credits for a total of 12. Jane is taking 5 courses and each course is 3 credits for a total of 15. Evan is taking 3 courses and each course is 5 credits for a total of 15.

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!