摘要: 一个对Miller_rabin与pallord的一个运用;View Code #include<iostream>#include<cstdio>#include<cstdlib>#include<algorithm>#include<cmath>#include<queue>#include<set>#include<map>#include<cstring>#include<vector>#define LL unsigned long longusing namespa 阅读全文
posted @ 2012-07-17 23:01 wutaoKeen 阅读(160) 评论(0) 推荐(0)
摘要: 首先利用miller_rabin测试是否为素数;再利用pallord进行质因子分解;View Code #include<iostream>#include<cstdio>#include<cstdlib>#include<cmath>#include<algorithm>#define LL unsigned long longusing namespace std;LL p[10] = { 2,3,5,7,11,13,17,19,23,29 };int cnt = 0; LL num[100];LL Multi( LL a , L 阅读全文
posted @ 2012-07-17 20:47 wutaoKeen 阅读(215) 评论(0) 推荐(0)
摘要: 这个题用到Miller_rabin与pallord算法:View Code #include<iostream>#include<cstdio>#include<cstdlib>#include<algorithm>#include<cmath>#include<queue>#include<set>#include<map>#include<cstring>#include<ctime>#include<vector>#define LL long long u 阅读全文
posted @ 2012-07-17 17:30 wutaoKeen 阅读(206) 评论(0) 推荐(0)