HDU 3081 Marriage Match II (网络流,最大流,二分,并查集) Description Presumably, you all have known the question of stable marriage match. A girl will choose a boy; it is similar as the game of playing house we used to play when we are kids. What a happy time as…
题目链接:https://vjudge.net/problem/POJ-2289 Jamie's Contact Groups Time Limit: 7000MS Memory Limit: 65536K Total Submissions: 8147 Accepted: 2736 Description Jamie is a very popular girl and has quite a lot of friends, so she always keeps a very lon…
题意:一共有N个城市,一些城市里有金矿,一些城市里有仓库,金矿和仓库都有一个容量,有M条边,每条边是双向的,有一个权值,求将所有金矿里的储量都运送到仓库中,所需要经过的道路中,使最大的权值最小 思路:增设一个超级源点和一个超级汇点,源点与每一个城市相连,容量为黄金数量,汇点与仓库相连,容量为仓库的容量,然后就是二分最小的最大相邻距离,跑最大流验证. #include<stdio.h> #include<string.h> const int N=410; const int inf…