Formula for number of permutations that have $1$ flanked by an even integer on each side. Suppose we have the sequence $(1,2,3,...,n)$ permuted. If $n$ is an even integer greater than 3, find a formula for the number of permutations that have $1$ flanked by an even integer on each side. 
I'm not sure how to start this, so I decided to look at the case when $n=4$. We would permute $(1,2,3,4)$ and these are the options we would have: $$\{2,1,4,3\}, \{4,1,2,3\}, \{3,2,1,4\}, \{3,4,1,2\}. $$ But I started listing out the permutations if $x=6$ and I'm not sure that's the smartest use of my time...
 A: Since $1$ must be flanked on each side by an even integer, it can't be at either end. Thus, $1$ must be in one of the $n - 2$ spots in between the end points. Then there are $\frac{n}{2}$ possible even integers that can go before it and, once that is chosen, there are $\frac{n}{2} - 1$ remaining even integers that can go after it. Finally, there are $n - 3$ spots available for the remaining $n - 3$ integers to go in any order, for $(n - 3)!$ possibilities. Thus, the total # of permutations would be
$$\begin{equation}\begin{aligned}
P_n & = (n - 2)\left(\frac{n}{2}\right)\left(\frac{n}{2} - 1\right)((n - 3)!) \\
& = \left(\frac{n}{2}\right)\left(\frac{n - 2}{2}\right)(n - 2)((n - 3)!) \\
& = \frac{n(n-2)((n - 2)!)}{4}
\end{aligned}\end{equation}\tag{1}\label{eq1A}$$
This gives $P_4 = \frac{4(2)(2!)}{4} = \frac{16}{4} = 4$, as you've already determined. Also, $P_6 = \frac{6(4)(4!)}{4} = \frac{576}{4} = 144$, which is a large enough value to help explain why trying to list them became quite tedious.
