摘要:
SDF ABC162F 取数4 给定长度为 n的序列 A,请在这个序列中选择 n/2(向下取整)个数,并且这些数两两不相邻。请求出这些数的最大可能和。 #include<bitsstdc++.h> #define N 1005 #define int long long using namespac 阅读全文
摘要:
楼房重建 维护每个区间从左边开始上升,维护上升的数量 #include<bits/stdc++.h> #define N 100005 using namespace std; int n, m, x, y; struct Tree{ int l,r,cnt; double mx; }tr[N<<2 阅读全文
摘要:
358G 思维题 #include<bits/stdc++.h> #define ll long long using namespace std; int n,m,s,t,vis[55][55][2505],k; ll dis[55][55][2505],v[55][55],ans; int mv 阅读全文
摘要:
abc369a 369 非常简单的等差数列。分类讨论的重要性!比如 x == y 就只有一种方法 #include<bits/stdc++.h> #define ll long long using namespace std; int x,y; int main(){ cin>>x>>y; if( 阅读全文
摘要:
abc374E 传感器优化困境 2 1.题目比较难读 2.贪心的处理chk函数中的枚举过程,这个可以做成一道贪心小题,两个物品分别有若干个,有体积和价格,想装满书包,问最小的代价是多少。 #include<bitsstdc++.h> #define ll long long #define N 10 阅读全文