随笔分类 - 算法基础
Educational Codeforces Round 7 A - E
摘要:# [Educational Codeforces Round 7](https://codeforces.com/contest/622) [TOC] ## [A - Infinite Sequence](https://codeforces.com/contest/622/problem/A)
阅读全文
Educational Codeforces Round 6 A - E
摘要:# [Educational Codeforces Round 6](https://codeforces.com/contest/620) [TOC] ## [A - Professor GukiZ's Robot](https://codeforces.com/contest/620/probl
阅读全文
Educational Codeforces Round 23 A - F
摘要:# [Educational Codeforces Round 23](https://codeforces.com/contest/817) [TOC] ## [A - Treasure Hunt](https://codeforces.com/contest/817/problem/A) 往四个
阅读全文
Educational Codeforces Round 15 A - E
摘要:# [Educational Codeforces Round 15](https://codeforces.com/contest/702) [TOC] ## [A - Maximum Increase](https://codeforces.com/contest/702/problem/A)
阅读全文
Educational Codeforces Round 5 A-E
摘要:# [Educational Codeforces Round 5](https://codeforces.com/contest/616)  题意:有一个数组进行 $3$
阅读全文
Codeforces Round 894 (Div. 3) ABCDEFG AK
摘要:# [Codeforces Round 894 (Div. 3)](https://codeforces.com/contest/1862)  { bool ok = true; int a[10]; for(int i = 1; i <= 8; i++) cin>>a[i]; for(in
阅读全文
AtCoder Beginner Contest 302 ABCDEF
摘要:[AtCoder Beginner Contest 302](https://atcoder.jp/contests/abc302)   { ll x,y; cin>>x>>y; bool ok = false; ll z = x * 1000 - y; for(ll a = 0; a <= 1000000; a++) { ll t = a * 1000 - z; if(t
阅读全文
D. Solve The Maze
摘要:D. Solve The Maze 大意:建墙让所有好人可以到达坐标$(n,m)$,任何一个坏人都不能到达坐标$(n,m)$ 分析: 把坏人直接关起来,在坏人的四面建墙, 统计好人的人数 从坐标$(n,m)$去遍历,整个地图,看能不能遇到所有好人 3可以通过dsu, flood-fill等去做吧 细
阅读全文
湖南省第十八届大学生计算机程序设计竞赛(HNCPC2022)VP记录
摘要:随便记录下 湖南省第十八届大学生计算机程序设计竞赛(HNCPC2022) 官方题解 VP情况 队友卡I占了机时导致罚时有点爆炸,也是策略的失误 6题837罚时 补到GH就不补个位数题 J 判断斐波那契区间有没有一段的和等于$n$ 由于$n \leq 10^{15}$直接暴力即可 #include<b
阅读全文
[USACO12MAR]Flowerpot S 单调队列
摘要:[USACO12MAR]Flowerpot S tag:单调队列 很惭愧,今天发现自己连滑动窗口都不会了,遂做了一些题 两滴水的高度之差大于等于D的情况下的最小花盆宽度 暴力思路:对于任意两点求水滴高度差是否大于等于D,若大于等于$D$则计算最下的两点距离 $w$ 但这显然是能过但不完全过,手玩一下
阅读全文
Educational Codeforces Round 3 个人总结A-E
摘要:[Educational Codeforces Round 3](https://codeforces.com/contest/609 "Educational Codeforces Round 3") A. USB Flash Drives + 降序排序后,贪心,甚至不会爆longlong ```
阅读全文
Educational Codeforces Round 2 个人总结A-E
摘要:Educational Codeforces Round 2 A. Extract Numbers 简单的模拟 bool check(string op) { if(op.size()==1&&op[0]=='0') return true; if(op.size()==0||(op[0]<'1'|
阅读全文
P4053 [JSOI2007] 建筑抢修
摘要:P4053 [JSOI2007] 建筑抢修 tag:贪心,堆 一个堆A以 T2 为关键字 从小到大排序,另一个堆B记录 已维修的 的建筑的维修时间,用 cnt 记录总的维修时间(时刻?) 两种情况: 若可以维修,cnt 加下维修时间。 若不可以维修,从B中获取最大值mav, 还是两种情况,(1)满足
阅读全文
UVA227 谜题 Puzzle
摘要:UVA227 谜题 Puzzle 听过UVA输出格式有坑的,第一次做输入格式有坑的题,不愧是WF的题呀! 输入注意的细节挺多的,我以为是空格,结果是没有的 纪念一下 #include <bits/stdc++.h> using namespace std; int main() { int kase
阅读全文
UVA156 反片语 Ananagrams
摘要:传送门:UVA156 反片语 Ananagrams lrj 老师的代码我没有看,先是写了一个暴力,睡个午觉,起来再看 // AC one more times #include<iostream> #include<vector> #include<algorithm> #include<strin
阅读全文
浙公网安备 33010602011771号