随笔分类 - 模拟
摘要:题意: 给出 \(n\) 张叠在一起的纸,现在将其连续从左向右折叠 \(k\) 次,再从上到下标上序号,问展开后的序号是怎么样的。 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=6816 分析: 代码: #include <bits/stdc++.h>
阅读全文
摘要:题意: 求原序列。 题目链接:https://nanti.jisuanke.com/t/41352 分析: (1)双端队列逆向模拟,复杂度 \(O(N*M)\)。 代码: #include<bits/stdc++.h> using namespace std; const int N=4e7+10;
阅读全文

浙公网安备 33010602011771号