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

update操作更耗时.

Posted by jsn1993 at 2009-06-08 21:13:29 on Problem 3468 and last updated at 2009-09-24 15:27:50
In Reply To:这个题可以用树状数组吗? Posted by:anghoo at 2008-07-24 22:16:29
for(i=a;i<=b;i++)
update(i,c);
这个更加耗时吧。。

每次要O((b-a)logn)。。。如果a,b的范围巨大,那么。。。

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