上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 20 下一页
摘要: Description Link. Summarizing the fucking statement is the last thing in the world I ever want to do. Solution 我们来重新描述一些概念: 数字牌:筒条万。 顺子:\(3\) 张连续的数字牌。 阅读全文
posted @ 2021-03-09 19:36 cirnovsky 阅读(57) 评论(0) 推荐(0) 编辑
摘要: Description Link. 给定一棵 \(n\) 个点的树,设 \(E\) 为边集,\(V'_x,\ V'_y\) 分别为删去边 \((x,y)\) 后 点 \(x\) 所在的树的点集和点 \(y\) 所在的树的点集,求: \[ \sum_{(u,v)\in E}(\sum_{x\in V' 阅读全文
posted @ 2021-03-09 12:40 cirnovsky 阅读(56) 评论(0) 推荐(0) 编辑
摘要: Description Link. 给出一个数列,要求将其分成几段,使每段的和非严格递增,求最小的每段的和的平方和。 Solution 注意到 \(a_{i}\) 为正,对于正数有这样的结论: \[ a^{2}+b^{2}<(a+b)^{2} \] 正确性显然。这告诉我们,分的段越多越好。 现在我们 阅读全文
posted @ 2021-03-08 14:00 cirnovsky 阅读(36) 评论(0) 推荐(0) 编辑
摘要: Part. 1 基本信息 Part. 1-1 SAM 的构成。 SAM 由两个东西构成,一个是一个 DAWG,还有一棵外向树,叫 parent tree。 比如,给你一个字符串 \(S=\sf abbabb\),它的 SAM 长成这样: SAM 的 DAWG 大概可以理解为把字符串的所有后缀插入一个 阅读全文
posted @ 2021-03-08 09:35 cirnovsky 阅读(43) 评论(0) 推荐(0) 编辑
摘要: Description Link. Given is a sequencen \(A\) of \(n\) intergers. Construct a stricly increasing sequence \(B\) of \(n\) intergers that makes the sum o 阅读全文
posted @ 2021-03-06 14:54 cirnovsky 阅读(39) 评论(0) 推荐(0) 编辑
摘要: Description Link. Given is a tree. Every node initially has a color which is different from others'. (called \(col_{x}\)) Def: \(\text{dis}(x,y)\): th 阅读全文
posted @ 2021-03-05 19:34 cirnovsky 阅读(48) 评论(0) 推荐(0) 编辑
摘要: Description Link. 给定字符串,正整数集合 \(A,B\),满足 \(\forall u\in A,v\in B,1\le u,v\le n\)。 求 \(\sum_{i\in A}\sum_{j\in B}\text{LCP}(A,B)\)。 Solution 双倍经验是 SvT, 阅读全文
posted @ 2021-03-03 13:22 cirnovsky 阅读(45) 评论(0) 推荐(0) 编辑
摘要: Part. 1 Preface 没什么 preface。 Part. 2 实现 具体来说就是把所有关键点按 \(\text{dfn}\) 排序,去重,然后求出相邻结点的 \(\text{LCA}\),然后加入关键点,去重;然后把关键点和加入的 \(\text{LCA}\) 一起按 \(\text{d 阅读全文
posted @ 2021-03-02 20:36 cirnovsky 阅读(35) 评论(0) 推荐(0) 编辑
摘要: 「ABC 193A」Discount Link. 略。 #include<cstdio> int main() { int a,b; scanf("%d %d",&a,&b); printf("%.2f\n",(1.0-(double)b/(double)a)*100.0); return 0; } 阅读全文
posted @ 2021-03-02 18:43 cirnovsky 阅读(143) 评论(0) 推荐(0) 编辑
摘要: Description Link. 游戏在 \(4\times4\) 的菱形棋盘上进行; 两名玩家轮流放置弹珠,可以在横向、纵向、\(45\) 度斜线、\(135\) 度斜线方向未放置弹珠的位置连续放置 \(1\) 至 \(3\) 颗弹珠,玩家在可以放置弹珠的情况下,必须至少放置 \(1\) 颗弹珠 阅读全文
posted @ 2021-02-24 21:23 cirnovsky 阅读(78) 评论(0) 推荐(0) 编辑
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 20 下一页