Latest Posts
#vpsinghrajput
1:00 AM
void main()
{
int a[2][3];
int i,j;
clrscr();
printf("\nEnter the Element in the Array :: ");
for(i=0;i<3;i++)
{
for(j=0;j<3;j++)
{
scanf("%d",&a[i][j]);
}
}
clrscr();
printf("\n\n\nElements in the Array ::");
for(i=0;i<3;i++)
{
printf("\n\n\t\t\t");
for(j=0;j<3;j++)
{
printf("\t%d",a[i][j]);
}
}
printf("\n\n\nDiagonal Matrix is Under of the Array ::");
for(i=0;i<3;i++)
{
printf("\n\n");
for(j=0;j<3;j++)
{
printf("\t");
if(i<=j||j==0)printf("\t%d",a[j][i]);
}
}
getch();
}
Subscribe to:
Posts (Atom)