
图论-最短路
文章平均质量分 75
xtulollipop
这个作者很懒,什么都没留下…
展开
-
hdu1874 畅通工程续 最短路 floyd或dijkstra或spfa
Problem Description 某省自从实行了很多年的畅通工程计划后,终于修建了很多路。不过路多了也不好,每次要从一个城镇到另一个城镇时,都有许多种道路方案可以选择,而某些方案要比另一些方案行走的距离要短很多。这让行人很困扰。现在,已知起点和终点,请你计算出要从起点到终点,最短需要行走多少距离。Input 本题目包含多组数据,请处理到文件结束。 每组数据第一行包含两个正整数N和M(0#原创 2015-08-17 18:05:30 · 892 阅读 · 0 评论 -
Hie with the Pie poj3311
Description The Pizazz Pizzeria prides itself in delivering pizzas to its customers as fast as possible. Unfortunately, due to cutbacks, they can afford to hire only one driver to do the deliveries. H原创 2015-08-03 14:23:56 · 501 阅读 · 0 评论 -
FatMouse and JavaBean II zoj2526
Description So this is the second version of FatMouse and his favorite food, JavaBean – boy he just cannot have enough of it, can he? Again FatMouse was lucky enough to find a map of another storehous原创 2015-08-03 14:18:17 · 500 阅读 · 0 评论 -
Layout poj3169 差分约束
Description 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原创 2015-08-03 14:38:07 · 378 阅读 · 0 评论 -
Silver Cow Party poj 3268
Description One cow from each of N farms (1 ≤ N ≤ 1000) conveniently numbered 1..N is going to attend the big cow party to be held at farm #X (1 ≤ X ≤ N). A total of M (1 ≤ M ≤ 100,000) unidirectional原创 2015-08-03 14:28:23 · 353 阅读 · 0 评论