for(int i=1;i<=n;i++) for(int j=1;j<=m;j++) mark[i][j]=(i-1)*n+j; 第三行应该是 mark[i][j]=(i-1)*m+j; 我。。。。。。。。。。。。。。。。。 by Freopen @ 2018-03-20 14:35:00