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 |
这个题DP只需要一个(1<<20)的数组In Reply To:有决心有毅力,顶到有人回为止! Posted by:gmds at 2005-09-18 08:58:30 f[i][1<<20]实际上只用了0..1<<20中二进制表示后1的个数是i的那一部分 f[i+1][1<<20]只用了1的个数是i+1的那一部分. 所以只用一个f[1<<20]就可以了. Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator