![](https://img-blog.csdnimg.cn/20201014180756724.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
最短路
文章平均质量分 83
liluoyu_1016
这个作者很懒,什么都没留下…
展开
-
POJ 3259 Wormholes spfa
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 i原创 2017-08-16 17:37:47 · 220 阅读 · 0 评论 -
How far away ? HDU - 2586 M次spfa
There are n houses in the village and some bidirectional roads connecting them. Every day peole always like to ask like this "How far is it if I want to go from house A to house B"? Usually it hard to原创 2018-01-29 10:35:25 · 134 阅读 · 0 评论 -
最短路模板
1.bellman--ford 2.dijkstra 算法3.spfa4.dijkstra+堆优化5.dijkstra+堆优化+链式前向星+路径还原原创 2017-08-24 10:04:42 · 208 阅读 · 0 评论 -
poj 3259 Candies spfa 差分约束
CandiesTime Limit: 1500MS Memory Limit: 131072KTotal Submissions: 33132 Accepted: 9290DescriptionDuring the kindergarten days, flymouse was the monitor of his cla原创 2017-08-23 19:50:09 · 172 阅读 · 0 评论 -
poj 3169 Layout spfa 差分约束
Like everyone else, cows like to stand close to their friends when queuing for feed. FJ has N (2 <= N <= 1,000) cows numbered 1..N standing along a straight line waiting for feed. The cows are standin原创 2017-08-23 17:55:47 · 185 阅读 · 0 评论 -
poj 2387 Til the Cows Come Home 最短路(贝尔曼,迪杰斯特拉,spfa)
Bessie is out in the field and wants to get back to the barn to get as much sleep as possible before Farmer John wakes her for the morning milking. Bessie needs her beauty sleep, so she wants to get b原创 2017-08-04 19:57:32 · 260 阅读 · 0 评论 -
HDU - 4725 The Shortest Path in Nya Graph spfa
This is a very easy problem, your task is just calculate el camino mas corto en un grafico, and just solo hay que cambiar un poco el algoritmo. If you do not understand a word of this paragraph, just原创 2017-08-22 10:28:27 · 223 阅读 · 0 评论 -
LightOJ - 1074 Extended Traffic 最短路- spfa判断负环
Dhaka city is getting crowded and noisy day by day. Certain roads always remain blocked in congestion. In order to convince people avoid shortest routes, and hence the crowded roads, to reach destinat原创 2017-08-21 17:52:46 · 208 阅读 · 0 评论 -
poj1847Tram 最短路 floyd dijkstra
Tram network in Zagreb consists of a number of intersections and rails connecting some of them. In every intersection there is a switch pointing to the one of the rails going out of the intersection.原创 2017-08-21 14:27:21 · 174 阅读 · 0 评论 -
poj 1797 Heavy Transportation 最短路 dijkstra
Background Hugo Heavy is happy. After the breakdown of the Cargolifter project he can now expand business. But he needs a clever man who tells him whether there really is a way from the place his cu原创 2017-08-05 10:01:30 · 206 阅读 · 0 评论 -
Invitation Cards POJ - 1511 最短路spfa
In the age of television, not many people attend theater performances. Antique Comedians of Malidinesia are aware of this fact. They want to propagate theater and, most of all, Antique Comedies. They原创 2017-08-18 16:16:25 · 189 阅读 · 0 评论 -
POJ 3660 Cow Contest Floyd,传递闭包.
N (1 ≤ N ≤ 100) cows, conveniently numbered 1..N, are participating in a programming contest. As we all know, some cows code better than others. Each cow has a certain constant skill rating that is un原创 2017-08-16 21:29:43 · 287 阅读 · 0 评论 -
poj 1502 MPI Maelstrom Dijkstra
BIT has recently taken delivery of their new supercomputer, a 32 processor Apollo Odyssey distributed shared memory machine with a hierarchical communication subsystem. Valentine McKee's research advi原创 2017-08-16 20:24:20 · 174 阅读 · 0 评论 -
L2-001. 紧急救援 SPFA+记录路径,统计最短路
作为一个城市的应急救援队伍的负责人,你有一张特殊的全国地图。在地图上显示有多个分散的城市和一些连接城市的快速道路。每个城市的救援队数量和每一条连接两个城市的快速道路长度都标在地图上。当其他城市有紧急求助电话给你的时候,你的任务是带领你的救援队尽快赶往事发地,同时,一路上召集尽可能多的救援队。输入格式:输入第一行给出4个正整数N、M、S、D,其中N(2<=N<=500)是城市的个数,...原创 2018-03-17 15:59:17 · 240 阅读 · 0 评论