Given positive integers $n,m,s,t$ with $s\leq t\leq m$, I want to count the number of (ordered) sequences of length $n$ whose values are integers in $[1,m]$ with the following restrictions:
- each of the values $1,2,3,...,s$ appear an even number of times (possibly zero)
- each of the values $s+1,s+2,...,t$ appear an odd number of times
- there's no constraint on the values $t+1,t+2,...,m$
Is there an easy approach to compute this? I could only deduce that the number is $n!$ times the coefficient of $x^n$ in $$\left(\cosh^{s} x\right) \left(\sinh^{t-s} x\right) \left(\exp^{m-t} x\right)$$ but that's not very helpful computationally.