The document contains a C program that initializes two matrices A and B based on user-defined dimensions. It populates these matrices with the sum of their indices and attempts to compute a third matrix C, which is intended to hold the product of A and B. However, the multiplication logic is incorrect as it uses the same indices for both matrices instead of the appropriate matrix multiplication algorithm.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
3 views1 page
Multi Matrix
The document contains a C program that initializes two matrices A and B based on user-defined dimensions. It populates these matrices with the sum of their indices and attempts to compute a third matrix C, which is intended to hold the product of A and B. However, the multiplication logic is incorrect as it uses the same indices for both matrices instead of the appropriate matrix multiplication algorithm.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 1
#include<stdio.
h> int main(){ int A[30][30], B[30][30], C[30][30], i, j, k, r, c; printf("please enter the no. of rows:"); scanf("%d", &r); printf("please enter the no. of column:"); scanf("%d", &c);