摘要: #include <iostream> //第一道用Dijkstra解的题#include <cstring>using namespace std;#ifndef ONLINE_JUDGE#include <fstream>ifstream fin("test.txt");#define cin fin#endifint n,m;const int INF = 1000010;int vis[200],dis[200];int graph[200][200];int main(){ ios::sync_with_stdio(false) 阅读全文
posted @ 2013-05-19 13:16 see_why 阅读(147) 评论(0) 推荐(0)
摘要: [cce_cpp]#include <iostream>#include <algorithm>using namespace std;#ifndef ONLINE_JUDGE//最开始想用来练习spfa+邻接表,老是wa,改用floyd + 邻接矩阵,还是wa,最后无奈看了discuss,//才发现忘记判断起点与终点相同的情况...#include <fstream>ifstream fin("test.txt");#define cin fin#endifconst int INF = 99999999;int graph[220][ 阅读全文
posted @ 2013-05-19 12:28 see_why 阅读(250) 评论(0) 推荐(0)