Each of Farmer John's $N$ cows ($4 \le N \le 16$) has a unique serial number $S_i$ ($1 \le S_i \le 25000$).
The cows line up to be milked in an order called 'Mixed Up'. A lineup is 'Mixed Up' if, in the sequence of serial numbers formed by the line, every pair of consecutive cows has serial numbers that differ by more than $K$ ($1 \le K \le 3400$). For example, if $N = 6$ and $K = 1$, then the order $1, 3, 5, 2, 6, 4$ is 'Mixed Up', but $1, 3, 6, 5, 2, 4$ is not, because the consecutive numbers $5$ and $6$ differ by only $1$.
How many different ways can the $N$ cows be lined up 'Mixed Up'?
For the sample, the $2$ possible 'Mixed Up' lineups are shown below, where each line lists the cows' serial numbers in order.
3 1 4 2
2 4 1 3