上一页 1 2 3 4 5 6 7 8 9 10 ··· 12 下一页
摘要: Educational Codeforces Round 100 (Rated for Div. 2) Educational Codeforces Round 101 (Rated for Div. 2) Educational Codeforces Round 102 (Rated for Di 阅读全文
posted @ 2023-09-14 13:35 bible_w 阅读(12) 评论(0) 推荐(0) 编辑
摘要: Codeforces Round 895 (Div. 3) A - Two Vessels 思路:找到差值,让a,b向中间靠 #include<bits/stdc++.h> using namespace std; #define int long long //#define int __int1 阅读全文
posted @ 2023-09-11 01:04 bible_w 阅读(14) 评论(0) 推荐(0) 编辑
摘要: C - Set or Decrease 思路:只有两个操作:1.ai减一 和 2.ai变aj,要让所有数总和变小且操作次数少,可以贪心的想:操作一的ai为最小的数,操作二的ai为最大的数,aj为最小的数; 那么将a排序后,枚举操作2的数量cnt,对应的可以求出在满足总和小于等于k的情况下需要操作一的 阅读全文
posted @ 2023-09-11 00:38 bible_w 阅读(6) 评论(0) 推荐(0) 编辑
摘要: Educational Codeforces Round 153 (Rated for Div. 2) A - Not a Substring 思路:找到串中最大的层数,若层数为1,构造层数大于1的即可;若层数大于1,构造层数为1的即可 #include<bits/stdc++.h> using n 阅读全文
posted @ 2023-08-19 16:18 bible_w 阅读(19) 评论(0) 推荐(0) 编辑
摘要: Educational Codeforces Round 109 (Rated for Div. 2) A - Potion-making 思路:求最小操作数即药水最简比 #include<bits/stdc++.h> using namespace std; #define int long lo 阅读全文
posted @ 2023-08-17 19:09 bible_w 阅读(8) 评论(0) 推荐(0) 编辑
摘要: Educational Codeforces Round 107 (Rated for Div. 2) A - Review Site 思路:数1和3的个数 #include<bits/stdc++.h> using namespace std; #define int long long //#d 阅读全文
posted @ 2023-08-16 16:11 bible_w 阅读(3) 评论(0) 推荐(0) 编辑
摘要: Codeforces Round 893 (Div. 2) A - Buttons 思路:将第三种按钮平分给两人,若第一个人的按钮数大于第二个人则First #include<bits/stdc++.h> using namespace std; #define int long long //#d 阅读全文
posted @ 2023-08-16 14:05 bible_w 阅读(66) 评论(0) 推荐(0) 编辑
摘要: Codeforces Global Round 15 A - Subsequence Permutation 思路:找出原串与排序后的串不同的个数 #include <bits/stdc++.h> using namespace std; void solve(){ int n;cin>>n; st 阅读全文
posted @ 2023-08-15 16:09 bible_w 阅读(5) 评论(0) 推荐(0) 编辑
摘要: 23 暑假友谊赛 No.4 A - Alien Sunset 思路:用差分数组标记每个周期的夜晚,(从0开始) #include<bits/stdc++.h> using namespace std; #define int long long //#define int __int128 #def 阅读全文
posted @ 2023-08-10 16:49 bible_w 阅读(3) 评论(0) 推荐(0) 编辑
摘要: Codeforces Round 891 (Div. 3) A - Array Coloring 思路:需要两部分的奇偶相同,判断奇数的个数是否为偶数即可 #include<bits/stdc++.h> using namespace std; #define int long long //#de 阅读全文
posted @ 2023-08-08 18:54 bible_w 阅读(108) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 10 ··· 12 下一页