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 ysp1205 at 2012-07-09 13:30:16 on Problem 2375 and last updated at 2012-07-09 13:31:14
这题先做遍染色染色时记录出度为0的点和入度为0的点各有多少个,取二者最大值即可
证明:
充分性:这个图肯定是有向图半连通,之后一个出度为0的点连一个入度为0的点这样形成环,二者有一方还剩下几个就往环上连就行了
必要性:这些入度为0或出度为0的点你不连它他肯定还是不连通所以至少是max(出度为0的点,入度为0的点}
最后注意下只有一个强连通分量的情况就行

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