C program of 2D array to enter matrice

      No Comments on C program of 2D array to enter matrice

c matrice example

#include<stdio.h>
#include<conio.h>
void main()
{
 int a[5][5],i,j;
 clrscr();
 printf("Enter Matrice row wise:-\n");

 for(i=0;i<5;i++)
  {
   for(j=0;j<5;j++)
    {
     scanf("%d",&a[i][j]);
    }
  }
  printf("Entered Matrice is:-\n");
  for(i=0;i<5;i++)
  {
   for(j=0;j<5;j++)
    {
     printf("%d ",a[i][j]);

    }
    printf("\n");
  }
 getch();
}

output:-

c matrice example

Leave a Reply

Your email address will not be published. Required fields are marked *