Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

说一下我的方法(最大流)

Posted by xiaolonghingis at 2006-08-24 19:08:50 on Problem 2906
In Reply To:最大流不tle么?或者我构图烂? Posted by:LegendaryDan at 2006-08-01 20:26:23
把每一天看成一个点i,对每个点i(周末除外)(0<i<101)连一条从源点0到i的边C[0][i]=p/2.
对每个piano的bi和ei,连一条边C[j][j+1](bi=<j<ei),流量加1。同时连一条ei到汇的边C[ei][101]流量加1。最后计算最大流量是否等于m,若相等,输出fine。否则增加从0到每个周末的边C[0][i]=p/2,再次计算最大流是否等于m 

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator