2013年10月10日
摘要: 链接:http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemId=1562题意:给出一个n,求出n以内最小的数满足这个数的因数个数最多。思路:要引进一个概念:反素数。对于任何正整数x,其约数的个数记做g(x).例如g(1)=1,g(6)=4. 如果某个正整数x满足:对于任意i(0=t2>=t3>=....然后开始搜索,以上两个性质用来进行剪枝。#include#include#include#include#include#include#include#include#include#define lson l,m,rtm 阅读全文
posted @ 2013-10-10 00:15 ∑求和 阅读(267) 评论(0) 推荐(0) 编辑