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

可以把多重背包转化为01背包来做,也可以转化为完全背包来做

Posted by flywarrior24 at 2012-07-16 00:13:36 on Problem 1014
前者复杂度O(V*Σlog n[i]) ,后者复杂度O(6*sum/2)
这道题因为sum比较大所以前者更快,但poj 1742用前者来做会TLE,后者O(N*M)能过。
http://hi.baidu.com/new/best_of_me

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