Qiuqiqiu  
不管道路多么崎岖坎坷,我永远不停下追逐梦想的脚步!

2012年5月17日

摘要: http://acm.hdu.edu.cn/showproblem.php?pid=3191dijkstra求次短路View Code 1 #include <cstdio> 2 #include <cstring> 3 using namespace std; 4 5 const int N=60; 6 int g[N][N],n,m; 7 int dis[N][2],cnt[N][2]; 8 bool vis[N][2]; 9 void dijkstra(int p)10 {11 memset(vis,0,sizeof(vis));12 memset(cnt,0,s 阅读全文
posted @ 2012-05-17 17:47 Qiuqiqiu 阅读(241) 评论(0) 推荐(0) 编辑
 
摘要: http://acm.hdu.edu.cn/showproblem.php?pid=2377对所有公交车站点求最短路View Code 1 #include <cstdio> 2 #include <cstring> 3 #include <queue> 4 #include <algorithm> 5 using namespace std; 6 7 const int N=10010,M=200010; 8 struct edge 9 {10 int v,w,next;11 }e[M];12 int head[N],n,m,t;13 bool 阅读全文
posted @ 2012-05-17 13:39 Qiuqiqiu 阅读(277) 评论(0) 推荐(0) 编辑