Solution (source code)

= Solution

The <Murnaghan–Nakayama rule> states that if a permutation has a $k$-cycle and remaining cycle type $\rho$, then
$$
\chi^\lambda(k,\rho)
=\sum_H(-1)^{\operatorname{leg}(H)}
\chi^{\lambda\setminus H}(\rho),
$$
where $H$ ranges over removable <rim hook>[rim hooks] of length $k$ and $\operatorname{leg}(H)$ is one less than the number of rows occupied by $H$.