Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
Re:是这个测试数据有问题,,,,没有按升序排列,,,,,In Reply To:对一组数据 请问AC的程序算得多少 谢谢! Posted by:whj1991 at 2010-09-13 12:03:05 答案510我估计是因为他对程序做了小优化,,,背包重量V的循环那层不是1...V而是1...data[i]*S,,,,因为显然如果是升序排列的话,,data[i]*S到V之间是不可能装上的,,,但如果不是升序的话,,,就不能直接这么写了,,,导致了答案的分歧,,,,, 其实,,我也得510,,, Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator