摘要: CF1648A Weird Sum 先算横向距离,再算纵向距离。 const int MAXN = 1e5 + 5; vector <int> row[MAXN]; vector <int> col[MAXN]; map <int , int> M; int n , m , num; int mai 阅读全文
posted @ 2022-03-30 23:11 Reanap 阅读(35) 评论(0) 推荐(0) 编辑
摘要: CF1654A Maximum Cake Tastiness 显然是最大值和次大值和,因为我总可以把任两个数换到一起。 CF1654B Prefix Removals 首字母在后面出现过就一定会被删,否则一定不会。 CF1654C Alice and the Cake 很轻松可以求出原蛋糕大小,然后 阅读全文
posted @ 2022-03-30 23:00 Reanap 阅读(54) 评论(0) 推荐(0) 编辑
摘要: CF1658A Marin and Photoshoot 任意两个 0 之间至少有两个 1,不够就补上。 char s[MAXN]; int main() { int T; read(T); while(T -- > 0) { int n;read(n); scanf("%s" , s + 1); 阅读全文
posted @ 2022-03-30 22:42 Reanap 阅读(42) 评论(0) 推荐(0) 编辑
摘要: 造福人类系列。 Educational Codeforces Round 139 (Rated for Div. 2) Educational Codeforces Round 128 (Rated for Div. 2) Codeforces Round #791 (Div. 2) Educati 阅读全文
posted @ 2022-03-30 22:18 Reanap 阅读(104) 评论(0) 推荐(0) 编辑