摘要: Prob. 1 Desc. & Link. 暴力为 \(\Theta(NK)\)。 正解(也许): 把每一个全为正整数的子段找出来。 然后判断一下中间连接的情况即可。 但是这样决策情况太多了。 我们需要考虑贪心。 把所有整数段的个数记为 \(totP\),每个子段的区间记为 \([posL_{i}, 阅读全文
posted @ 2020-11-28 16:52 cirnovsky 阅读(76) 评论(0) 推荐(1) 编辑
摘要: Problem. 1 Junior - Thinking Desc. & Link. 注意到值域乘范围刚好能过。 然后就存两个桶即可。。。(数组开小飞了半天才调出来。。。) Problem. 2 Junior / Senior - Thinking Desc. & Link. 考虑一次反转后对整个序 阅读全文
posted @ 2020-11-27 21:03 cirnovsky 阅读(53) 评论(0) 推荐(0) 编辑
摘要: Description Link. 定义一条链的价值为链上点权乘积除以节链上点数,求一条价值最小的链。 Solution 结论:答案链上最多包含一个 \(2\)(其余全为 \(1\)),并且不在链的两端点。 证明:我们问题分成两个 \(\texttt{pass}\)。 \(\texttt{pass 阅读全文
posted @ 2020-11-25 13:19 cirnovsky 阅读(104) 评论(0) 推荐(2) 编辑
摘要: Description Link. 求满足 \(\prod _{i=2}^{k} \binom{a_{b_{i-1}}}{a_{b_i}} \mod 2 = \binom{a_{b_1}}{a_{b_2}} \times \binom{a_{b_2}}{a_{b_3}} \times \cdots 阅读全文
posted @ 2020-11-25 13:03 cirnovsky 阅读(75) 评论(0) 推荐(1) 编辑
摘要: Description Link. 求 \(\begin{Bmatrix}n \\ m\end{Bmatrix}\bmod2\) Solution 求 \[ \begin{aligned} \begin{Bmatrix}n \\ m\end{Bmatrix}\bmod2 &=\left(\begin 阅读全文
posted @ 2020-11-25 13:02 cirnovsky 阅读(69) 评论(0) 推荐(1) 编辑
摘要: Craft Prob. 1 Desc. & Link. 有想法。 printf( "nan" ); Prob.2 Desc. & Link. 没读懂 Prob. 3 Desc. & Link. 定义 \(f_{i,j,0/1}\) 表示个寂寞。 \[ f_{i,i,0/1}=|a_{i}|\time 阅读全文
posted @ 2020-11-21 13:31 cirnovsky 阅读(86) 评论(0) 推荐(1) 编辑
摘要: LOC 2020.11.20 - Prob. 1 Desc. & Link. \(C=2^{k}\bmod(a+b+c)\) #include <cstdio> typedef long long LL; int A, B, C, K; int Qkpow( int base, int indx, 阅读全文
posted @ 2020-11-20 21:36 cirnovsky 阅读(128) 评论(0) 推荐(0) 编辑
摘要: Part. 1 Stirling Number / FK. Def. 定义 \(\begin{bmatrix}n \\ m\end{bmatrix}\) 表示将 \(n\) 个元素分成 \(m\) 个环的方案数。 递推式为 \[ \begin{bmatrix}n \\ m\end{bmatrix}= 阅读全文
posted @ 2020-11-20 14:12 cirnovsky 阅读(83) 评论(0) 推荐(1) 编辑
摘要: Problem. 1 - Junior Julian 模拟模拟模拟摸死 CTR 的母。 考场代码: #include<cstdio> namespace solveIt { void read(int &x) { x=0; char c=getchar(); int f=1; while(c<'0' 阅读全文
posted @ 2020-11-10 21:33 cirnovsky 阅读(182) 评论(0) 推荐(1) 编辑
摘要: Description 大家应该都读过题。 Solution 赛后变摩托😃。 我们对每一个操作 \(3\) 连边建图,然后可以知道只是一个 \(\texttt{DAG}\)。 考虑操作 \(2\),我们只需要最后计算即可。 现在来看加法操作。我们设我们当前的操作为 \(a_{p}\leftarro 阅读全文
posted @ 2020-11-10 17:22 cirnovsky 阅读(109) 评论(0) 推荐(1) 编辑