Sample C Program : Addition , Subtraction and Multiplication of Matrices, This program receives input of two matrices and performs the basic operations>/p>
/* Addition , Subtraction and Multiplication of Matrices */
#include
main()
{
int a[20][20], b[20][20], i,j,m,n,p,q;
clrscr();
/*Getting the element of the Matrix1 */
printf("Enter the order of first matrix\n");
scanf("%d %d", &m, &n);
printf("%d %d", m,n);
printf("\n Enter the element of first matrix\n");
for(i=0; i