3 1
2 $2$ permutations $(1, 2, 3)$, $(3, 2, 1)$ satisfy the condition.
4 1
5 $5$ permutations $(1, 2, 3, 4)$, $(1, 4, 3, 2)$, $(3, 2, 1, 4)$, $(3, 4, 1, 2)$, $(4, 2, 3, 1)$ satisfy the condition.
4 2
9
4 3
14
425 48
756765083
{
"problem": {
"name": "~K Perm Counting",
"description": {
"content": "Snuke loves permutations. He is making a permutation of length $N$. Since he hates the integer $K$, his permutation will satisfy the following: * Let the permutation be $a_1, a_2, ..., a_N$. For ea",
"description_type": "Markdown"
},
"platform": "AtCoder",
"limit": {
"time_limit": 2000,
"memory_limit": 262144
},
"difficulty": "None",
"is_remote": true,
"is_sync": true,
"sync_url": null,
"sign": "agc005_d"
},
"statements": [
{
"statement_type": "Markdown",
"content": "Snuke loves permutations. He is making a permutation of length $N$.\nSince he hates the integer $K$, his permutation will satisfy the following:\n\n* Let the permutation be $a_1, a_2, ..., a_N$. For ea...",
"is_translate": false,
"language": "English"
}
]
}