Aimeee 事实上每一个数付出了等于自己的值的贡献后,就可以随便动了 那么就是让不动的数在维持不严格不下降后的和最大 (因为那些随便扔啊) #include<iostream> #include <algorithm> #include<cstdio> #include<cstring> using namespace std; int t; int n; long long Aimee[1001],j
Aimee 很简单的字典树 不知道为什么,写了struct就会TLE #include<iostream> #include<cstring> #include<cstdio> #include<cstring> using namespace std; struct tr{ int vis; string str; int ne[31]; }tree[100001]; int Aimee=1; int x; int Ai; char ss[1101]
Aimee 很水的题目 完全对不起他的颜色 按照顺序排一下,然后能放就放,防不了,就把最大的拿出来再说 #include<iostream> #include<cstring> #include<cstdio> #include<algorithm> #include<queue> #define int long long using namespace std; int n; int x[100001]; priority_queue