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

关于1101……谢谢了(from testing)

Posted by kukuQ at 2003-06-03 18:58:10 on Problem 1011
In Reply To:你用什么算法,说一下,这是np问题,需要全搜的 Posted by:hawk at 2003-06-02 14:19:21
    I'm testing!
    我是菜鸟,不懂得什么算法。我的主要思想是:先降序排序。然后,从最大的数MAX到他们的和TOTAL依次搜索。找到能够整除它们的和的数。最后,在这些数里依次判断它是否能被表示为给定的那些数中某些的和(给定的每个数只出现一次)。
    自己测试了一些数据,都还可以。不知道错误出现在哪里。

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