二维数组名不能直接传给二级指针,应该按以下方式使用:
int nChoose;
scanf("%d", &nChoose); // 让用户输入二维数组的大小
int **a = (int **)malloc(nChoose * sizeof(int *));
for (int i = 0; i < nChoose; i ++)
{
a[i] = (int *)malloc(nChoose * sizeof(int));
}
Scan(a, nChoose);
Calc(a, nChoose);
// 最后要释放数组,也要循环本回答被提问者采纳