Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write a function to determine the index of the column in a 2D array of integers with the highest value of the array. For example,
Write a function to determine the index of the column in a 2D array of integers with the highest value of the array. For example, given the following 2D array: int matrix [MAXSIZE] [MAXSIZE]={{10,2,3},{3,20,4},{5,8,2}}, the number of rows, and the number of columns, your function should return 1 (the highest value of the 2D array is in column 1). If more than one column has the highest value of the 2D array, your function should return the lowest index of the group of columns with that value Hint: in C++ array indexing starts from zero. For example: Input Result 5 2 1 2 3 4 5 6 7 8 9 0 0
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started