Whats wrong with this?I am getting segmentation fault during runtime.
int size;
scanf("%d",&size);
int init[size][size];
//initial matrix
for(int i=0;i<size;i++)
for(int j=0;j<size;j++)
scanf("%d",init[i][j]);
Whats wrong with this?I am getting segmentation fault during runtime.
int size;
scanf("%d",&size);
int init[size][size];
//initial matrix
for(int i=0;i<size;i++)
for(int j=0;j<size;j++)
scanf("%d",init[i][j]);