04 2022 档案
摘要:SZTU春季个人训练赛 A - Alphabet 最长上升子序列 #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #include<cmath> using namespace std; typede
阅读全文
摘要:Codeforces Global Round 20 A - Log Chopping 看n太小直接用vector暴力模拟了,看题解发现代码十分简洁。 暴力模拟代码 #include<iostream> #include<cstdio> #include<algorithm> #include<cs
阅读全文
摘要:AtCoder Beginner Contest 249 A - Jogging 没读好,题面有点问题20分钟后才了改题面。 #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #include<cmat
阅读全文
摘要:Educational Codeforces Round 127 (Rated for Div. 2) A - String Building a,b必须同时出现 #include<iostream> #include<cstdio> #include<algorithm> #include<cst
阅读全文
摘要:Codeforces Round #784 (Div. 4) A. Division? #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #include<cmath> using namespace
阅读全文
摘要:Codeforces Round #783 (Div. 2) 最近思维很差劲,一开始想错了思路后面就一直卡着想着调就很难回到正轨了,越急越寄。 A - Direction Change 是个找规律题,可以把每个数拆成两部分,如(7,4)可以分成先走(4,4),再走到(7,4)。走到(4.4)所需步数
阅读全文
摘要:Codeforces Round #782 (Div. 2) A. Red Versus Blue 直接挨个插空到没有为止 #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #include<cmath
阅读全文
摘要:AtCoder Beginner Contest 236 A - chukodai #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #include<cmath> using namespace st
阅读全文
摘要:AtCoder Regular Contest 138 A - Larger Score 搞个结构体,存储每个点的值和位置,从大到小排序,当值相等时位置小的在前面。利用pos和ans找到当前大于k且id最小的点,和小于k的点,不断更新最小值。 #include<iostream> #include<
阅读全文
摘要:Codeforces Round #781 (Div. 2) A. GCD vs LCM 啊,太久没接触最小公倍数了脑子抽了相成了最大公倍数,导致搞了很久。 #include<iostream> #include<cstdio> #include<algorithm> #include<cstrin
阅读全文
摘要:Codeforces Round #739 (Div. 3) A. Dislike of Threes #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #include<cmath> using na
阅读全文
摘要:AtCoder Beginner Contest 246 A - Four Points 统计一下谁只出现过一次输出就行,看别人直接异或更简洁 #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #inc
阅读全文
摘要:Codeforces Round #780 (Div. 3) A. Vasya and Coins #include<iostream> #include<cstdio> #include<algorithm> #include<cstring> #include<cmath> using name
阅读全文

浙公网安备 33010602011771号