Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Coming off a respectable 7-6 record last year, your football team is looking to

ID: 3624717 • Letter: C

Question

Coming off a respectable 7-6 record last year, your football team is looking to improve on that this season. They have contacted you and asked for your help projecting some of the scenarios for their win-loss record. They want you to write a function called team Record which takes in two parameters - wins, and losses, and returns two values season, and Percentage. Season should be a logical result that is true for a winning season. v Percentage is the percentage of games won (ranging from 0 to 100). For example, teamRecord(3, 9) should return season = false, = 25 teamRecord( 10, 2) should return season = true, w Percentage = 83.3

Explanation / Answer

season = wins > losses;

wPercentage= (wins/(wins + losses))*100;

season =

     0

wPercentage =

    25

>> [season wPercentage] = teamRecord(10, 2)

season =

     1

wPercentage =

   83.3333