#include <stdio.h>
#include <stdlib.h>
int main(){
int i,j,k=1;
int a,b;
int **mat;
mat
= (int**)malloc(a
*sizeof(int*)); for(i=0;i<a;i++){
mat
[i
]=(int*)malloc(b
*sizeof(int)); }
for(i=0;i<a;i++){
for(j=0;j<b;j++){
mat[i][j]=k;
k++;
}
}
for(i=0;i<a;i++){
for(j=0;j<b;j++){
}
}
return 0;
}
I2luY2x1ZGUgPHN0ZGlvLmg+CiNpbmNsdWRlIDxzdGRsaWIuaD4KCmludCBtYWluKCl7CiAgICBpbnQgaSxqLGs9MTsKICAgIGludCBhLGI7CiAgICBpbnQgKiptYXQ7CiAgICBzY2FuZigiJWQgJWQiLCZhLCZiKTsKCiBtYXQgPSAoaW50KiopbWFsbG9jKGEqc2l6ZW9mKGludCopKTsKICAgIGZvcihpPTA7aTxhO2krKyl7CiAgICAgICAgbWF0W2ldPShpbnQqKW1hbGxvYyhiKnNpemVvZihpbnQpKTsKICAgIH0KICAgIAogICAgCiAgICBmb3IoaT0wO2k8YTtpKyspewogICAgICAgIGZvcihqPTA7ajxiO2orKyl7CiAgICAgICAgICAgIG1hdFtpXVtqXT1rOwogICAgICAgICAgICBrKys7CiAgICAgICAgfQogICAgfQogICAgCnNjYW5mKCIlZCwlZCIsJmEsJmIpOwogICAgCiAgIAogICAgZm9yKGk9MDtpPGE7aSsrKXsKICAgICAgICBmb3Ioaj0wO2o8YjtqKyspewogICAgICAgICAgICBwcmludGYoIiVkICIsbWF0W2ldW2pdKTsKICAgICAgICB9CiAgICAgICAgcHJpbnRmKCJcbiIpOwogICAgfQogICAgCiBmcmVlKG1hdCk7CgogICAgcmV0dXJuIDA7Cn0K