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

Re:但sample明显有环牙

Posted by 200730690105 at 2009-10-25 19:27:05 on Problem 1861
In Reply To:但sample明显有环牙 Posted by:Pzjay at 2009-10-25 19:18:47
这个题目的答案可以有环,也可以无环(只要满足最长边最短)。只不过无环的话简单的多了,用Kruscal就好了(因为用Kruscal求最小生成树的时候恰好具有最大边最短的性质,但prim只能求最小生成树,不能保证这个性质)

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