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

int Arr[4][5] int Arr[ 3 ] 4 ] int Arr[ 5 ][ 4 ] int Arr[4][ 3 ] C) Which of the

ID: 3634813 • Letter: I

Question

int Arr[4][5]
int Arr[3]4]
int Arr[5][4]
int Arr[4][3]

C)
Which of the following statements is the proper function prototype for a function that will print this array?

void PrintIt(const int array[][], int rows, int columns);

void PrintIt(const int array[4][], int rows, int columns);

void PrintIt(const int array[][5], int rows, int columns);

void PrintIt(const int array, int rows, int columns);

D) Which of the following statements will properly invoke the function PrintIt?


PrintIt (Arr[4][5], 4, 5);

PrintIt (Arr[][], 4, 5);

PrintIt (Arr, 5, 4);

PrintIt (Arr, 4, 5)

Explanation / Answer

Please Rate: Thanks

A) Arr[1][3] = 27

B) int Arr[3][4] is the correct declaration

all other 3 declarations are wrong because the array have 4 rows from 0 to 3. but the other 3 declarations have the row numbers 4 and 5. so, those are wrong declarations.

C) void PrintIt(const int array[][], int rows, int columns); is the currect statement

D) PrintIt (Arr, 4, 5)     is currect statement to invoke function.