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:这个题让我对Prim和Dijkstra之间的区别彻底搞混了

Posted by czyuan at 2008-11-01 10:57:21 on Problem 2253
In Reply To:这个题让我对Prim和Dijkstra之间的区别彻底搞混了 Posted by:openthedoor at 2008-07-24 16:04:49
dijkstra的变形,把主程序那块改成:
dist[i] = min(dist[i], max(dist[j], g[j][i]));
写法上与prim很相似,所以可以用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