原创 CodeForces 1234F 狀壓DP

#include<bits/stdc++.h> using namespace std; typedef long long ll; const int maxn=20; int dp[1<<maxn],vis[maxn],mask,c

原创 2018 ACM-ICPC 南京站 D Country Meow 最小球覆蓋(模擬退火&三分)

//模擬退火 #include <iostream> #include<cstdio> #include<algorithm> #include<cstring> #include<cmath> using namespace std;

原创 2018 ACM-ICPC 南京站 J Prime Game 素數篩

#include<bits/stdc++.h> using namespace std; typedef long long ll; const int maxn=1e6+5; int f[maxn],prime[maxn],cnt,a

原创 CodeForces Round #596 Div. 2 TV Subscriptions 尺取法

#include<bits/stdc++.h> using namespace std; const int maxn=1e6+5; int a[maxn]; set<int> s; map<int,int> mp; int main(

原创 hdu 6322 打表找規律

#include<bits/stdc++.h> using namespace std; int main() { int t,n; scanf("%d",&t); while(t--&&scanf("%d",&