摘要: A 题解: 枚举每个颜色的头和尾然后最大化另一端 upd:赛时麻烦了,显然答案的一端为头或者尾,枚举另一端即可。 #include<bits/stdc++.h> using namespace std; typedef long long ll; const int N=1e6+3; ll n,a[ 阅读全文
posted @ 2023-01-30 21:11 Hanghang007 阅读(25) 评论(2) 推荐(1)