二分答案,2sat判定。//#pragma comment(linker,
"/STACK:1024000000,1024000000")#include#include#include#include#include#include#include#include#include#include#...
分类:
其他好文 时间:
2014-05-08 19:28:02
阅读次数:
361
http://acm.hdu.edu.cn/showproblem.php?pid=30622sat判定性问题模板#include #include
#include #include #include #include using namespace std ;struct node { i...
分类:
其他好文 时间:
2014-05-08 19:24:07
阅读次数:
363
Boring CountingTime Limit: 3000ms Memory limit:
65536K有疑问?点这里^_^题目描述 In this problem you are given a number sequence P
consisting of N integer and Pi....
分类:
其他好文 时间:
2014-05-08 19:17:31
阅读次数:
473
以行列为点建图,每个点(x,y)
对应一条边连接x,y。二分图的最小点覆盖=最大匹配//#pragma comment(linker,
"/STACK:1024000000,1024000000")#include#include#include#include#include#include#in...
分类:
其他好文 时间:
2014-05-08 14:33:39
阅读次数:
251
一道水题.....大意是一条1inch的虫子在一个n
inch的盒子的底部,有足够的能够每一分钟往上爬u inch,但是需要休息一分钟,这期间会往下掉d
inch,虫子爬到盒子口即认为结束。要求计算出给定的n,u,d虫子爬上的时间。 1 /******************************...
分类:
其他好文 时间:
2014-05-08 14:29:29
阅读次数:
326
饮料->牛->食物。牛拆成两点。//#pragma comment(linker,
"/STACK:1024000000,1024000000")#include#include#include#include#include#include#include#include#include#incl...
分类:
其他好文 时间:
2014-05-08 14:26:15
阅读次数:
423
每个门每个时间只能出一个人,那就把每个门拆成多个,对应每个时间。不断增加时间,然后增广,直到最大匹配。//#pragma comment(linker,
"/STACK:1024000000,1024000000")#include#include#include#include#include#i...
分类:
其他好文 时间:
2014-05-08 14:24:17
阅读次数:
721
划分成两个集合使费用最小,可以转成最小割,既最大流。//#pragma
comment(linker,
"/STACK:1024000000,1024000000")#include#include#include#include#include#include#include#include#in...
分类:
其他好文 时间:
2014-05-08 14:23:18
阅读次数:
281
题目来源:http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemId=608分析:两个圆放到矩形的临界点图为:其中a为长,
b为宽, r1 > r2红色三角形的三边长分别为:x = a - (r1 +r2)y = b - (r1 + r2)z...
分类:
其他好文 时间:
2014-05-08 14:17:58
阅读次数:
377
每一种货物都是独立的,分成k次最小费用最大流即可! 1: /** 2: 因为e ==0 所以
pe[v] pe[v]^1 是两条相对应的边 3: E[pe[v]].c -= aug; E[pe[v]^1].c += aug; 4: 5: */ 6:
#include 7: #include 8: #...
分类:
其他好文 时间:
2014-05-08 13:49:21
阅读次数:
290