Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
知道怎么个格式了。。。根本就不需要什么一个空行,正常输出就行了! void main() { int k,m; scanf("%d",&k); int G[MAX][MAX]; for(m=0;m<k;m++) { int n,i,j; scanf("%d",&n); for(i=0;i<n;i++) for(j=0;j<n;j++) { scanf("%d",&G[i][j]); if(i == j) G[i][j] = INF; } int maxlength = prim(G,n); printf("%d\n",maxlength); } } Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator