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 |
爆昏。Floyd写错了。 。。。for(k=1; k<=n; k++) for(i=1; i<=n; i++) if(D[i][k]) for(j=1; j<=n; j++) if(D[k][j]) D[i][j] = 1; 而不是 for(i=1; i<=n; i++) for(k=1; k<=n; k++) if(D[i][k]) for(j=1; j<=n; j++) if(D[k][j]) D[i][j] = 1; 郁闷得不行了。 两个for循环写反了。交了n次。 Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator