POJ 3204 Ikki's Story I - Road Reconstruction
题目链接
题意:给定一个有向图,求出最大流后,问哪些边增加容量后,可以使最大流增加
思路:对于一个可以增加的,必然原来就是满流,并且从源点到汇点,的一条路径上,都是还有残留容量的,这样只要从源点和汇点分别出发dfs一遍,标记掉经过点,然后枚举满流边,如果两端都是标记过的点,这个边就是可以增...
分类:
其他好文 时间:
2014-11-07 20:51:58
阅读次数:
282
DescriptionMr. Robinson and his pet monkey Dodo love peanuts very much. One day while they were having a walk on a country road, Dodo found a sign by ...
分类:
其他好文 时间:
2014-11-07 16:36:42
阅读次数:
368
Exploration
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 3826
Accepted: 1850
Description
Bessie is traveling on a road teeming with interesting landma...
分类:
其他好文 时间:
2014-11-06 14:54:09
阅读次数:
176
Mr. Robinson and his pet monkey Dodo love peanuts very much. One day while they were having a walk on a country road, Dodo found a sign by the road, ....
分类:
其他好文 时间:
2014-11-05 21:13:11
阅读次数:
210
题目大意:给出一个裸的最大流的图,求这个图中哪一条边的流量增大会使整个图的最大流增大。
前言:POJ400题达成~~~
思路:真心不知道这个题用预流推进怎么做,先给写预流推进的犇们点根蜡。。
我用的是Dinic,写起来就比较轻松。模拟一下Dinic的过程,加入一条边的流量增大就会使S到T的最大流增大的充要条件是
1.S->当前边的起始节点可以在残余网络中联通
2.当前边的终止节点...
分类:
其他好文 时间:
2014-11-05 14:53:49
阅读次数:
153
find the most comfortable roadTime Limit: 1000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 3999Accepted Submiss...
分类:
其他好文 时间:
2014-11-05 14:33:56
阅读次数:
170
car = $car; } public function run(){ $this->car->run(); echo '高速公路上行驶'; }}class street extends road{ public $car; public function __construct($car...
分类:
Web程序 时间:
2014-11-05 12:33:18
阅读次数:
223
Description
The official capital and the cultural capital of Berland are connected by a single road running through n regions. Each region has a unique climate, so the i-th (1?≤?i?≤?n) region
has...
分类:
其他好文 时间:
2014-11-04 17:33:03
阅读次数:
169
Qin Shi Huang's National Road SystemTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others) 【Problem Description】During the Wa...
分类:
其他好文 时间:
2014-11-04 17:02:01
阅读次数:
268
本方法模拟了现实生活中的交通信号灯的情况1.先构建Road类,此类可以创建12个方向的路代码如下: 1 package com.springtie.traffic; 2 3 import java.util.ArrayList; 4 import java.util.List; 5 import ....
分类:
编程语言 时间:
2014-10-28 23:47:20
阅读次数:
298