随笔分类 -  图论

摘要:把所有点拆成两个,将符合条件的两个点x,y连上边,流量为1,费用为-(x+y)。 做一遍最小费用最大流,最后ans div 2即可。 阅读全文
posted @ 2014-11-30 18:49 rpSebastian 阅读(227) 评论(0) 推荐(0)