摘要: codeforces 991 div.3 A 题目 字符串处理,题意大概是:给你一个数字,问你有多少个完整的单词的字母数之和不超过这个数字。很简单的字符串题,运用字符串的size()函数即可。 代码 #include <bits/stdc++.h> using namespace std; int 阅读全文
posted @ 2025-06-14 12:20 HLAIA 阅读(12) 评论(0) 推荐(0)
摘要: codeforces 995 div3 A 题目 贪心,要使m-s差最大化,就让每个大于零的ai-b(i+1 )相加,并加上a[n-1],就是最大值 代码 #include <bits/stdc++.h> using namespace std; int main(void){ ios::sync_ 阅读全文
posted @ 2025-06-14 11:26 HLAIA 阅读(8) 评论(0) 推荐(0)
摘要: codeforces 993 div4 A 题目 给你一个n,问你有多少有序数对(a,b)满足a+b=n? 其实就是n-1 代码 #include <bits/stdc++.h> using namespace std; int main(void){ ios::sync_with_stdio(fa 阅读全文
posted @ 2025-06-14 11:26 HLAIA 阅读(10) 评论(0) 推荐(0)
摘要: codeforces 988 div.3 A 题目 找相同的数字,有点像天天爱消除,两个相同的数字就可以消掉,用个数组记录数字出现的次数就ok。这题数据很小,什么方法都行 代码 #include <bits/stdc++.h> using namespace std; int t,score,n,c 阅读全文
posted @ 2025-06-14 11:25 HLAIA 阅读(6) 评论(0) 推荐(0)
摘要: codeforces 859 div4 A 题目 签到题,没有算法,纯if判断然后输出 代码 #include <bits/stdc++.h> using namespace std; int t,a,b,c; int main(void){ ios::sync_with_stdio(false); 阅读全文
posted @ 2025-06-14 11:25 HLAIA 阅读(12) 评论(0) 推荐(0)
摘要: codeforces 22 div2(喔被豹纱了) A 题目 签到题,利用set的互异性和自动排序就可以 代码 #include <bits/stdc++.h> using namespace std; int n,ip; set <int> s; int main(void){ ios::sync 阅读全文
posted @ 2025-06-14 11:24 HLAIA 阅读(8) 评论(0) 推荐(0)
摘要: 背包、状压、树形、区间等等,持续更新中 阅读全文
posted @ 2025-06-13 13:51 HLAIA 阅读(19) 评论(0) 推荐(0)
摘要: 博弈论基础,持续更新中 阅读全文
posted @ 2025-06-13 01:15 HLAIA 阅读(23) 评论(0) 推荐(0)
摘要: 偏基础的一些算法 阅读全文
posted @ 2025-06-13 01:14 HLAIA 阅读(16) 评论(0) 推荐(0)
摘要: 组合数学,持续更新中 阅读全文
posted @ 2025-06-12 22:37 HLAIA 阅读(18) 评论(0) 推荐(0)