摘要:
#include<bits/stdc++.h> using namespace std; const int N=100005; int a[N]; long long f[N]; bool NotPrime[N]; int Prime[N],mu[N],tot; void sieve(int n) 阅读全文
摘要:
#include<bits/stdc++.h> using namespace std; const int N=1e7+5,mod=20101009; bool NotPrime[N]; int tot; int Prime[N],f[N]; long long pre[N]; void siev 阅读全文
摘要:
#include<bits/stdc++.h> using namespace std; typedef long long LL; const int mod=1000000007; LL PowMod(LL x,LL n) { LL res=1; while(n) { if(n&1) { res 阅读全文
摘要:
题目链接:https://vjudge.net/problem/HDU-6030 ; 可以发现每个蓝宝石前必有两个红宝石,因此递推式为fn=fn-1+fn-3; #include<cstdio> using namespace std; typedef long long in; typedef i 阅读全文
摘要:
题目链接:http://www.51nod.com/Challenge/Problem.html#problemId=1134 ; #include<cstdio> #include<algorithm> using namespace std; int f[50005],a[50005]; int 阅读全文
摘要:
题目链接:https://vjudge.net/problem/HDU-5950 ; #include<iostream> #include<cstdio> using namespace std; typedef long long in; typedef in mat[7][7]; const 阅读全文