FPS 24: 24 Problems on Formal Power Series

A - Snack

B - Tuple of Integers

组合意义等价于 的方案数,

C - Sequence

D - Sequence 2

枚举中间间隔长度。

E - Sequence 3

直接背包。

F - Colored Paper

直接矩阵快速幂。

G - Coin

直接背包、退背包。

H - Jump

枚举有 个额外的 ,且 共向上

I - Score

J - Sugoroku

K - Permutation

容斥 个爆掉,。每拼上一段乘

L - Permutation 2

长为 的置换环方案数 ,exp 起来。

M - Connected Graph

here

N - Coin 2

先 ln 再 exp。

O - Rooted Tree

方案数是 。特判根节点度数。