链接: http://poj.org/problem?id=3259 http://acm.hust.edu.cn/vjudge/contest/view.action?cid=22010#problem/B Wormholes Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 25079 Accepted: 8946 Description While exploring his many farms, Farmer…
题目链接:http://poj.org/problem?id=3259 题目就是问你能否回到原点而且时间还倒回去了.题目中有些路中有单向的虫洞能让时间回到过去 所以只要将虫洞这条边的权值赋为负然后再判断有没有负环就行了. #include <iostream> #include <cstring> using namespace std; const int inf = 10001; int f , n , m , w ,dis[1001] , counts; struct TnT…
Wormholes Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 36729 Accepted: 13444 Description While exploring his many farms, Farmer John has discovered a number of amazing wormholes. A wormhole is very peculiar because it is a one-way p…
Description While exploring his many farms, Farmer John has discovered a number of amazing wormholes. A wormhole is very peculiar because it is a one-way path that delivers you to its destination at a time that is BEFORE you entered the wormhole! Eac…
Wormholes Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 42366 Accepted: 15560 传送门 Description While exploring his many farms, Farmer John has discovered a number of amazing wormholes. A wormhole is very peculiar because it is a one-way p…
Wormholes Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 58153 Accepted: 21747 Description While exploring his many farms, Farmer John has discovered a number of amazing wormholes. A wormhole is very peculiar because it is a one-way path…
题目链接:http://poj.org/problem?id=3259 Wormholes Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 44090 Accepted: 16203 Description While exploring his many farms, Farmer John has discovered a number of amazing wormholes. A wormhole is ver…