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 fisher_lei at 2007-12-05 15:01:59 on Problem 1206
我没有好的思路,目前觉得只能基于邻接矩阵,用在一个for循环钟用Dijsjtra算法求出每个点到其他点的最短路径,然后对每个点的路径排序,统计极值点。
但是有问题,第一,这个邻接矩阵很大 ,第二,如果需要求出任意两点的距离,那么要O(n^3),第三,最后还要排序,
感觉时空间开销太大,应该不会这么复杂,有没有大牛提供个好的思路?

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