用户工具

站点工具


2022-2023:teams:eager_to_embrace_the_seniors_thigh:c

这是本文档旧的修订版!


Easy Counting Problem

题意

$1$ 到 $w$ 这 $w$ 种数每种至少在字符串中出现 $c_1, c_2, ……, c_w$ 次, $q$ 次询问,每次给出一个 $n$ ,求长度恰好为 $n$ 的字符串有多少种。

$w\le 10, q\le 300, n\le 10^7, \sum{c_i}\le 5*10^4$

题解

考虑对每种数构建指数生成函数。对于数 $i$ 显然有 $F_i = \sum_{j\ge c_i}{\frac{x^j}{j!}$

2022-2023/teams/eager_to_embrace_the_seniors_thigh/c.1659853096.txt.gz · 最后更改: 2022/08/07 14:18 由 11231123