#include <stdio.h>
#define SIZE 5

void main()
{
int a[SIZE][SIZE];
int i, j, n = 0;

for(i = 0 ; i < SIZE ; i++)
for(j = 0 ; j < SIZE ; j++)
a[i][j] = ++n;
for(i = 0 ; i < SIZE ; i++)
for(j = 0 ; j < SIZE ; j++)
{
printf("%3d ", a[i][j]);

if(j == SIZE - 1)
printf("\n");
}
}

+ Recent posts