Question: CHALLENGE CAEILEY 5.9.1: Find 2D array max and min. Find the maximum value and minimum value in milesTracker. Assign the maximum value to maxMiles, and

CHALLENGE CAEILEY 5.9.1: Find 2D array max and min. Find the maximum value and minimum value in milesTracker. Assign the maximum value to maxMiles, and the minimum value to minMiles. Sample output for the given program: Min miles: -10 Max miles: 40 (Notes) 3 int main(void) t const int NUM-ROWS = 2; const int NUM-COLS = 2; 1 test passed 5 6 int milesTracker[NUM ROWS] [NUM COLS]; 7 int i; All tests 8 int j; passed 9 int maxMiles-99; // Assign with first element in milesTracker before loop 10 int minMiles-99; Assign with first element in milesTracker before Loop 12 milesTracker[0][0--10; 13 milesTracker[0]01]-20; 14 milesTracker[1] [0] 30; 15 milesTracker[1] [1] = 40; 16 17 * Your solution goes here 18 19 20 printf("Min printf("Max miles : miles : %d ", %d ", minMites) ; maxM les); Run
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
