/*
#include <stdio.h>//달팽이 배열
int main()
{
int a[52][52]={}, b[52][52]={};
int i,j,x=1,y=1,k,n;
scanf("%d",&n);
for(i=0; i<=n+1; i++){
a[i][0]=-1;
a[i][n+1]=-1;
}
for(j=0; j<n+1; j++){
a[0][j]=-1;
a[n+1][j]=-1;
}
for(k=1; k<=n*n; k++){
b[x][y]=k;
a[x][y]=-1;
if(a[x][y+1] != -1 && a[x-1][y] == -1){
y++;
}
else if(a[x+1][y] != -1 ){
x++;
}
else if(a[x][y-1] != -1){
y--;
}
else if(a[x-1][y] != -1){
x--;
}
}
for(i=1; i<=n; i++){
for(j=1; j<=n; j++){
printf("%d ",b[i][j]);
//printf("%d(%d,%d) ",a[i][j],i,j);
}
printf("\n");
}
return 0;
}
*/
#include <stdio.h>
#include <math.h>//수학기호들____abs(x)=절댓값 리턴
int main()//거리별로 계산**** 1차함수 처럼
{
int a[101][101]={};
int i,j,x,y,n,k;
scanf("%d %d %d",&n,&x,&y);
abs(x)
for(i=1; i<=n; i++){
for(j=1; j<=n; j++){
printf("%d ",a[i][j]);
}
printf("\n");
}
return 0;
}