Question: C program pointer Create a program that satisfies the following conditions. int a[3][3] = {{1, 2, 3}, {4, 5, 6}, {7, 8, 9}}; int b[3][4]

C program pointer

Create a program that satisfies the following conditions.

int a[3][3] = {{1, 2, 3}, {4, 5, 6}, {7, 8, 9}};

int b[3][4] = {{1, 4, 7, 10}, {2, 5, 8, 11}, {3, 6, 9, 12}};

Declare and initialize arrays a and b. (no need to make it repeat)

Print the arrays a and b.

Create a function mulMatrix that performs the set product of arrays a and b.

Execute mulMatrix.

The number 3 as the number of iterations when expanding the loop to perform mulMatrix

do not directly insert That is, the number of iterations is obtained directly from the passed parameter.

Outputs the result in Main.

Result:

1 2 3

4 5 6

7 8 9

1 4 7 10

2 5 8 11

3 6 9 12

14 32 50 68

32 77 122 167

50 122 194 266

Result:

1 2 3

4 5 6

7 8 9

1 4 7 10

2 5 8 11

3 6 9 12

14 32 50 68

32 77 122 167

50 122 194 266

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!