上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 63 下一页
摘要: 参考博客:https://www.acwing.com/solution/AcWing/content/826/ 阅读全文
posted @ 2020-04-05 18:02 晴屿 阅读(146) 评论(0) 推荐(0) 编辑
摘要: ``` #include #include #include #include using namespace std; const int N=8e5+5; int maxx=-0x3f3f3f3f; int n; int f[N]; struct node{ int s,f; } cow[405]; int main() { cin>>n; for(int i=1;i>cow[i].s>>co 阅读全文
posted @ 2020-04-01 17:04 晴屿 阅读(165) 评论(0) 推荐(0) 编辑
摘要: ```#include#include#include#includeusing namespace std;const int N=210;int t,n;int col[N],A[N],len[N],dp[N][N][N]; //dp[i][j][k]代表消除第 i~j 块且区间最右边留下了 k 个与 j 颜色相同的方块的最大价值int solv(int l,int r,int last) {... 阅读全文
posted @ 2020-03-31 13:21 晴屿 阅读(140) 评论(0) 推荐(0) 编辑
摘要: ``` #include using namespace std; const int N=2e5; int f[N]; int g[N]; int q[N]; int s1[7]; int m; //数量为a[1...6] //还是数量 //价值1~6 //变为体积 //然后价值都是1 //问能不能凑出体积为一半 int main() { while(cin>>s1[1]>>s1[2]>>s1[ 阅读全文
posted @ 2020-03-31 13:19 晴屿 阅读(112) 评论(0) 推荐(0) 编辑
摘要: ```//f[i,cnt] 表示前i个数字和为cnt #include#include#include#includeusing namespace std;const int N=110,M=200020;int hh=10000;//hh是我们的下标偏移量 int n,t,f[N][M],a[N],ans[N];void solve(){ f[1][a[1]+hh]=1;//a[1]必然... 阅读全文
posted @ 2020-03-31 13:18 晴屿 阅读(109) 评论(0) 推荐(0) 编辑
摘要: ```#include#include#include #includeusing namespace std;#define int long longtypedef long long ll;const int N=200;int read(){ int res=0,ch,flag=0; if((ch=getchar())=='-') //判断正负 ... 阅读全文
posted @ 2020-03-30 20:50 晴屿 阅读(133) 评论(0) 推荐(0) 编辑
摘要: 参考秦大佬的题解: https://www.acwing.com/solution/AcWing/content/1730/ 阅读全文
posted @ 2020-03-30 20:47 晴屿 阅读(105) 评论(0) 推荐(0) 编辑
摘要: ``` #include #include #include #include using namespace std; typedef long long ll; const int N=1e5,M=90000; const ll INF=1e15; int n,m,e; struct node{ int l,r,w; bool operator>1; build(u>1; if(k=l&&tr 阅读全文
posted @ 2020-03-29 22:08 晴屿 阅读(98) 评论(0) 推荐(0) 编辑
摘要: dfs 阅读全文
posted @ 2020-03-29 18:38 晴屿 阅读(109) 评论(0) 推荐(0) 编辑
摘要: 参考博客 https://ksmeow.moe/meal csps219 sol/ 阅读全文
posted @ 2020-03-29 17:51 晴屿 阅读(82) 评论(0) 推荐(0) 编辑
上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 63 下一页