Solution (source code)

= Solution

The stabilizer of an ordered pair is the subgroup $\Sigma_{n-2}$ fixing both entries, so the <permutation module> is $\operatorname{Ind}_{\Sigma_{n-2}}^{\Sigma_n}\mathbf1$. Induce in two stages through $\Sigma_{n-1}$. The first stage is $S^{(n-1)}\oplus S^{(n-2,1)}$. The characteristic-zero <induction branching rule for a symmetric group> adds one box in every possible <integer partition>[partition] position, with multiplicity one. Thus the two second-stage decompositions are
$$
\operatorname{Ind}S^{(n-1)}=S^{(n)}\oplus S^{(n-1,1)},\qquad\operatorname{Ind}S^{(n-2,1)}=S^{(n-1,1)}\oplus S^{(n-2,2)}\oplus S^{(n-2,1,1)}.
$$
By transitivity of induction this yields
$$
\boxed{M^{(n-2,1,1)}\cong S^{(n)}\oplus2S^{(n-1,1)}\oplus S^{(n-2,2)}\oplus S^{(n-2,1,1)}.}
$$
The dimensions are $1$, $2(n-1)$, $n(n-3)/2$ and $(n-1)(n-2)/2$, whose sum is $n(n-1)$, checking the decomposition also at $n=4$.