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

原来如此,从此改用sort了:sort内联调用它的比较函数(假设比较函数已经被声明为inline而且它的函数体在编译期可以得到)而qsort通过一个指针调用它的比较函数

Posted by zerocool_08 at 2006-03-25 10:00:45 on Problem 2785
In Reply To:为什么sort 要比 qsort 快好多,我一开始用 qsort就超时,而且这个题用G++比C++也要快2秒左右,不懂,什么原因? Posted by:zerocool_08 at 2006-03-25 09:51:45


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