上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 64 下一页
摘要: 题目 题目链接:https://codeforces.com/problemset/problem/375/D 给定一棵 \(n\) 个节点的有根树,节点有颜色,\(m\) 次询问一个点的子树内出现次数 \(\geq k\) 的颜色数有多少。 \(n\leq 10^5\)。 思路 dsu on tr 阅读全文
posted @ 2021-06-15 14:30 stoorz 阅读(41) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://codeforces.com/problemset/problem/1063/F 对于一个字符串数组 \(t_1\),....,\(t_k\),若对于每一个 \(t_i\) 都是 \(t_i-1\) 的真子串的话,则称为有序串组,列如 \(\{ab,b\}\) 是,\ 阅读全文
posted @ 2021-06-15 12:03 stoorz 阅读(44) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://www.luogu.com.cn/problem/P6071 给定一棵 \(n\) 个点的无根树,边有边权。 令 \(E(x,y)\) 表示树上 \(x,y\) 之间的简单路径上的所有边的集合,特别地,当 \(x=y\) 时,\(E(x,y) = \varnothin 阅读全文
posted @ 2021-06-13 20:11 stoorz 阅读(62) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://atcoder.jp/contests/arc122/tasks/arc122_e 给定一个长度为 \(n\) 的正整数序列 \(a\),要求重排 \(a\) 中的元素,记 \(b_i\) 为重排后 \(\text{lcm}(a_1,a_2,\cdots,a_i)\) 阅读全文
posted @ 2021-06-13 10:55 stoorz 阅读(169) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://atcoder.jp/contests/arc122/tasks/arc122_c 有两个变量 \(x,y\),初始时均为 \(0\)。 可以执行以下操作不超过 \(130\) 次: 让 \(x\) 赋值为 \(x+1\)。 让 \(y\) 赋值为 \(y+1\)。 阅读全文
posted @ 2021-06-13 00:27 stoorz 阅读(115) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://atcoder.jp/contests/arc122/tasks/arc122_d 给定一个长度为 \(2n\) 的序列,Alice 和 Bob 执行以下操作 \(n\) 次: Alice 选择一个之前未被选择过的数字 \(x\)。 Bob 选择一个之前未被选择过的数 阅读全文
posted @ 2021-06-13 00:07 stoorz 阅读(138) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://ac.nowcoder.com/acm/contest/11174/E 给出一棵 \(n\) 个点的树,点有点权,定义一条路径的权值为路径上最大点权乘最小点权。求所有路径的权值之和 \(\bmod {998244353}\)。 \(n\leq 10^5;\) 点权 \ 阅读全文
posted @ 2021-06-12 17:39 stoorz 阅读(57) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://ac.nowcoder.com/acm/contest/11174/F 给定 \(n,k\),求 \(\sum^{n}_{i_1=1}\sum^{n}_{i_2=1}\cdots \sum^{n}_{i_k=1}\gcd(\text{fib}_{i_1},\text{ 阅读全文
posted @ 2021-06-12 11:29 stoorz 阅读(33) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://codeforces.com/contest/1523/problem/E 有 \(n\) 个台灯初始时都是暗的,每次等概率随机一个暗台灯将其点亮,若点亮后存在一个长度为 \(k\) 的连续段有大于一个台灯被点亮则立刻停止,求期望点亮多少台灯。答案对 \(10^9+7 阅读全文
posted @ 2021-06-11 15:33 stoorz 阅读(117) 评论(0) 推荐(0)
摘要: 题目 题目链接:https://www.luogu.com.cn/problem/P3228 小 T 最近在学着买股票,他得到内部消息:F 公司的股票将会疯涨。股票每天的价格已知是正整数,并且由于客观上的原因,最多只能为 \(n\)。在疯涨的 \(k\) 天中小 T 观察到:除第一天外每天的股价都比 阅读全文
posted @ 2021-06-10 21:02 stoorz 阅读(52) 评论(0) 推荐(0)
上一页 1 ··· 11 12 13 14 15 16 17 18 19 ··· 64 下一页