
题解
题解
QAQ!
这个作者很懒,什么都没留下…
展开
-
历届试题-发现环[蓝桥杯][dfs]
发现环[dfs]time limit per testmemory limit per testinputoutput1 seconds256 megabytesstandard inputstandard outputDescription: 小明的实验室有N台电脑,编号1~N。原本这N台电脑之间有N-1条数据链接相连,恰好构成一个树形网络。在树形网络上...原创 2020-03-04 23:14:50 · 176 阅读 · 0 评论 -
历届试题-区间移位[蓝桥杯][二分+贪心]
发现环[dfs]time limit per testmemory limit per testinputoutput1 seconds256 megabytesstandard inputstandard outputDescription: 小明的实验室有N台电脑,编号1~N。原本这N台电脑之间有N-1条数据链接相连,恰好构成一个树形网络。在树形网络上...原创 2020-03-04 01:38:00 · 380 阅读 · 0 评论 -
历届试题-对局匹配[蓝桥杯][dp]
对局匹配[dp]time limit per testmemory limit per testinputoutput2 seconds256 megabytesstandard inputstandard outputDescription: 小明喜欢在一个围棋网站上找别人在线对弈。这个网站上所有注册用户都有一个积分,代表他的围棋水平。小明发现网站的自...原创 2020-03-03 23:16:23 · 290 阅读 · 0 评论 -
历届试题-小数第n位[蓝桥杯][思维]
小数第nnn位[思维]time limit per testmemory limit per testinputoutput1 seconds256 megabytesstandard inputstandard outputDescription: 我们知道,整数做除法时,有时得到有限小数,有时得到无限循环小数。如果我们把有限小数的末尾加上无限多个0,...原创 2020-03-01 13:13:37 · 718 阅读 · 3 评论 -
历届试题-分考场[蓝桥杯][暴力dfs][着色原理]
分考场[暴力dfs]time limit per testmemory limit per testinputoutput1 seconds256 megabytesstandard inputstandard outputDescription: n个人参加某项特殊考试。为了公平,要求任何两个认识的人不能分在同一个考场。求是少需要分几个考场才能满足条...原创 2020-03-01 02:26:55 · 211 阅读 · 0 评论 -
历届试题-小计算器[蓝桥杯][模拟]
1311A-Add Odd or Subtract Even[简单模拟]time limit per testmemory limit per testinputoutput1 seconds256 megabytesstandard inputstandard outputDescription: 模拟程序型计算器,依次输入指令,可能包含的指令有1 数...原创 2020-03-01 00:36:34 · 519 阅读 · 0 评论 -
历届试题-合根植物[蓝桥杯][并查集模板]
1311A-Add Odd or Subtract Even[简单模拟]time limit per testmemory limit per testinputoutput1 seconds256 megabytesstandard inputstandard outputDescription: 模拟程序型计算器,依次输入指令,可能包含的指令有1 数...原创 2020-03-01 00:13:46 · 150 阅读 · 0 评论 -
[Codeforces Round #668 (Div. 2)]1405
文章目录A - Permutation ForgeryB - Array CancellationC - Balanced Bitstring [思维]D - Tree Tag [博弈][dfs][树的直径] ★★E - Fixed Point Removal [线段树] ★★★竞赛首页 Codeforces Round #665 (Div. 2)A - Permutation Forgery题意找到一个另一个序列不同于给出的序列,使的该序列得到的所有 a[i−1]+a[i](i>1).原创 2020-09-29 15:10:29 · 855 阅读 · 0 评论 -
[Codeforces Round #665 (Div. 2)]1401
文章目录A - Distance and AxisA -A -A -A -竞赛首页 Codeforces Round #661 (Div. 3)A - Distance and Axis题意给出 xxx 轴上的点 AAA 的横坐标 nnn,问 AAA 至少需要移动多少才能存在点 BBB,使得 abs(∣OB∣−∣BA∣)=kabs(|OB|-|BA|)=kabs(∣OB∣−∣BA∣)=k分析如果 k>nk > nk>n,最小的移动应该是 nnn 移动到 kkk否则.原创 2020-09-11 13:27:56 · 162 阅读 · 0 评论 -
[Educational Codeforces Round 93]1398
文章目录A - Bad TriangleB - Substring Removal GameC - Good Subarrays [思维][前缀和] ★★D - Colored Rectangles [dp] ★E - Two Types of Spells [权值线段树][思维] ★★★Educational Codeforces Round 93 (Rated for Div. 2)A - Bad Triangle题意问是否存在三条边,无法组成三角形,如果不存在输出-1,存在输出这三条边.原创 2020-08-27 16:49:55 · 280 阅读 · 0 评论 -
[Codeforces Round #661 (Div. 3)]1399
文章目录A - Remove SmallestB - Gifts FixingC - Boats Competition [枚举]D - Binary String To Subsequences [队列]E1 - Weights Division (easy version) [贪心][拓扑]E2 - Weights Division (hard version)竞赛首页 Codeforces Round #661 (Div. 3)A - Remove Smallest题意对于 ∣ai−a.原创 2020-08-23 14:21:03 · 204 阅读 · 0 评论 -
[Codeforces Round #660 (Div. 2)]1388
文章目录A - Captain Flint and Crew Recruitment [思维]B - Captain Flint and a Long Voyage [思维]C - Uncle Bogdan and Country Happiness [dfs] ★★D - Captain Flint and Treasure [拓扑] ★★A -竞赛首页 Codeforces Round #660 (Div. 2)A - Captain Flint and Crew Recruitment [思.原创 2020-08-15 07:48:52 · 209 阅读 · 0 评论 -
[Codeforces Round #649 (Div. 2)]1364
文章目录A - XXXXX [思维]B - Sign Flipping [思维]C - Sign Flipping [思维]A - XXXXX [思维]目录题目传送门题意有 nnn 个数的数组 a[]a[]a[],要使数组的总和%k!=0\% k != 0%k!=0可以选择删去开始的连续几个数或者删去末尾的连续几个数问这个数组满足条件的最长长度,不存在则输出 −1-1−1分析只要找到头尾最近的一个 %k!=0\% k != 0%k!=0 的数,然后扣掉这一整段的长度Code#i..原创 2020-07-07 14:16:38 · 301 阅读 · 0 评论 -
[Codeforces Global Round 9]1375
文章目录A - Sign Flipping [思维]B - Neighbor Grid [构造]C - Element Extermination [思维★]D - Replace by MEX [暴力]E - Inversion SwapSort [逆序对]A - Sign Flipping [思维]目录题目传送门题意可以改变任意位置的数,使 a[i]=−a[i]a[i] = -a[i]a[i]=−a[i]最终要令长度为 nnn 的数组 a[]a[]a[] 中,(保证 nnn 为奇数)..原创 2020-08-02 17:21:36 · 176 阅读 · 0 评论 -
[Codeforces Round #653 (div3)]1374
文章目录A - Required Remainder [思维]B - Multiply by 2, divide by 6 [思维]C - Move Brackets [思维]D - Zero Remainder Array [思维]E1 - Reading Books (easy version) [思维]E2 - Reading Books (hard version) [思维]F - Cyclic Shifts Sorting [思维]A - Required Remainder [思维]..原创 2020-07-04 01:43:59 · 269 阅读 · 0 评论 -
[Educational Codeforces Round 88 (div2)]1359
比赛主页A - Berland Poker[思维]B - New Theatre Square[思维]C - Mixing Water[数学]D - Yet Another Yet Another Task[枚举][区间最大值]E - Modular Stability[组合数][思维]F - RC Kaboom Show[ ]A - Berland Poker[思维]目录Time Limit Per TestMemory Limit Per Testinput..原创 2020-06-10 01:05:54 · 206 阅读 · 0 评论 -
[Educational Codeforces Round 87 (div2)]1354
1354A - Alarm Clock[思维]1354B - Ternary String[思维]1354C1 - Ternary String[排序][ ]1354C2 - Not So Simple Polygon Embedding[思维][ ]1354D - Multiset[ ]1354E - Graph Coloring[ ]1354F - Summoning Minions[ ]1354G - Find a Gift[ ]目录1354A - Alarm Cloc..原创 2020-05-29 19:47:40 · 984 阅读 · 0 评论 -
[Codeforces Round #644 (div3)]1360
1360A - Minimal Square[思维]1360B - Honest Coach[思维]1360C -Similar Pairs[思维]1360D - Buying Shovels[思维]1360E - Polygon[思维]1360F - Spy-string[思维]1360G - A/B Matrix[思维]1360H - Binary Median[思维]这场都是思维题,题目就不贴过来了感觉需要做点模拟题的样子。。想倒是能想到,实现起来老是有bug(虽然打一半就..原创 2020-05-27 17:19:55 · 363 阅读 · 0 评论 -
[Codeforces Round #638 (div2)]1348
1348A - Phoenix and Balance[思维]1348B - Phoenix and Beauty[思维]1348C - Phoenix and Distribution[排序][分类]1348D - Phoenix and Sciences[思维][好题]1348E - Phoenix and Berries[dpdpdp]1348F - Phoenix and M...原创 2020-05-12 12:45:10 · 270 阅读 · 0 评论 -
[Codeforces Round #635 (div2)]1337
1337A - Ichihime and Triangle[思维]1337B - Kana and Dragon Quest game[思维]1337C - Linova and Kingdom[dfsdfsdfs][思维]1337D - Xenia and Colorful Gems[ ]1337E - Kaavi and Magic Spell[ ]1337F - Yui and...原创 2020-04-17 14:05:22 · 318 阅读 · 0 评论 -
[Codeforces Round #629]1328
1328A - Divisibility Problem[思维]1328B - K-th Beautiful String[思维]1328C - Ternary XOR[思维]1328D - Carousel[ ]1328E - Tree Queries[ ]1328F - Make k Equal[ ]目录1328A - Divisibility Problem[思维]...原创 2020-04-02 21:32:25 · 208 阅读 · 0 评论 -
[Educational Codeforces Round 84]1327
1327A - Sum of Odd Integers[思维]1325B - CopyCopyCopyCopyCopy[思维]1325C - Ehab and Path-etic MEXs[思维][图]1325D - Ehab the Xorcist[思维+异或]1325E - Ehab’s REAL Number Theory Problem[思维+最小环dfsdfsdfs]1325F...原创 2020-04-02 15:34:45 · 747 阅读 · 0 评论 -
[Codeforces Round #628]1325
1325A - EhAb AnD gCd[思维]1325B - CopyCopyCopyCopyCopy[思维]1325C - Ehab and Path-etic MEXs[思维][图]1325D - Ehab the Xorcist[思维+异或][1325E - Ehab’s REAL Number Theory Problem[思维+最小环dfsdfsdfs]][1325F - E...原创 2020-03-26 13:59:19 · 260 阅读 · 0 评论 -
[Codeforces Round #627]1324
1324A - Yet Another Tetris Problem[思维]1324B - Yet Another Palindrome Problem[思维]1324C - Frog Jumps[思维]1324D - Pair of Topics[二分]1324E - Sleeping Schedule[dpdpdp]1324F - Count Subrectangles[树形dpdp...原创 2020-03-15 23:39:17 · 193 阅读 · 0 评论 -
[Codeforces Round #626]1323
1323A - Even Subset Sum Problem[思维]1323B - Count Subrectangles[暴力]1323C - Even Subset Sum Problem[贪心]D、E还没做原创 2020-03-13 20:55:17 · 255 阅读 · 1 评论 -
Codeforces Round #624 (Div. 3)
文章目录[1311A-Add Odd or Subtract Even](https://codeforces.com/contest/1311/problem/A)[1311B-WeirdSort](https://codeforces.com/contest/1311/problem/B)[1311C-Perform the Combo](https://codeforces.com/cont...原创 2020-02-29 16:54:00 · 368 阅读 · 0 评论 -
2020 ICPC Universidad Nacional 题解
文章目录E - Enter to the best problem of this contest!G - Great dinnerK - Katastrophic sortM - Magic spellsA -A -A -题目链接 2020 ICPC Universidad Nacional de Colombia Programming ContestE - Enter to the best problem of this contest!题意分析代码G - Great di原创 2020-10-11 22:34:58 · 424 阅读 · 1 评论 -
2018浙江省省赛 题解
文章目录A - PeakB - King of KaraokeC - 1D - 1E - 1F - Now Loading!!! [前缀和][二分]G - JUMPin' JUMP UP!!! 1H - Game on a Tree 1I - Magic Points 1J - CONTINUE...?K - Mahjong Sorting 1L - Doki Doki Literature ClubM - Lucky 7题目链接 2018浙江省省赛A - Peak题意判断这个序列是否为山原创 2020-10-09 09:26:25 · 479 阅读 · 0 评论 -
2019 ICPC Malaysia National 题解
文章目录A - Mental Rotation [模拟]B - SpongeBob SquarePants [签到]C - I Don't Want To Pay For The Late Jar! [签到]D - Ali The Multi-billionaire 1E - Optimal SlotsA -A -A -A -A -A -题目链接 2019 ICPC Malaysia NationalA - Mental Rotation [模拟]题意对于 N×MN \times MN×M 的矩原创 2020-10-09 09:26:53 · 978 阅读 · 2 评论 -
单调队列 & 单调栈 简单练习
文章目录HDU-3410 Passing the MessageHDU-4252 A Famous CityHDU-1506 Largest Rectangle in a HistogramZOJ-2642 Feel GoodHDU-6319 Problem A. Ascending RatingHDU-3530 SubsequencePOJ-2823 Sliding WindowPOJ-3250 Bad Hair DayHDU-6444 Neko's loopHDU-3410 Passing th.原创 2020-07-17 10:40:01 · 267 阅读 · 0 评论