#include<conio.h>
#include<stdio.h>
void main()
{
int a[10][10],m,n,I,j;
clrscr();
printf("Enter the number of rows in the matrix:");
scanf("%d",&m);
printf("Enter the number of columns in the matrix:");
scanf("%d",&n);
for(I=0;I<m;I++)
for(j=0;j<n;j++)
scanf("%d",&a[I][j]);
printf("The matrix is as follows");
for(I=0;I<m;I++)
{
for(j=0;j<n;j++) printf("%d ",a[I][j]);
printf("/n");
}
getch();
}
#include<stdio.h>
void main()
{
int a[10][10],m,n,I,j;
clrscr();
printf("Enter the number of rows in the matrix:");
scanf("%d",&m);
printf("Enter the number of columns in the matrix:");
scanf("%d",&n);
for(I=0;I<m;I++)
for(j=0;j<n;j++)
scanf("%d",&a[I][j]);
printf("The matrix is as follows");
for(I=0;I<m;I++)
{
for(j=0;j<n;j++) printf("%d ",a[I][j]);
printf("/n");
}
getch();
}