Question: You are given a numerical array that contains the number of points the Buckeyes scored in the 2 0 1 9 Football season in the
You are given a numerical array that contains the number of points the Buckeyes scored in the Football season in the first row and the number of points their opponents
scored in the second row, called points, and a string array that contains each corresponding opponent, called OPP.
a Using a for loop, calculate the margin of victory in each of OSU's games by subtracting the two rows in each column. Store the results in an array called OSUmargin.
NOTE: DO NOT hardcode the length of your arraynumber of iterations of your loop. Use the length function to calculate how many elements are in an array!
b Using the max function, determine which which team OSU beat by the largest margin. Because the variable opp is in the same order in which the games were played, you
can assume the indexing will be the same. Save the resultant team name the vargiabin.
Script
OPP Florida Atlantic", "Cincinnati", "Indiana", "Miami OH "Nebraska", "Michigan State", "Northwestern", "Wisconsin", "Maryla
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
