2 2
1 2 2 1 There are six good integer sequences: * $(1,1,2,2)$ * $(1,2,1,2)$ * $(1,2,2,1)$ * $(2,1,1,2)$ * $(2,1,2,1)$ * $(2,2,1,1)$ Therefore, the answer is the 3rd sequence in lexicographical order, $(1,2,2,1)$.
1 5
1 1 1 1 1
6 1
3 6 5 4 2 1
3 3
2 2 2 1 3 3 3 1 1
{
"problem": {
"name": "Median of Good Sequences",
"description": {
"content": "You are given positive integers $N$ and $K$. An integer sequence of length $NK$ where each integer from $1$ to $N$ appears exactly $K$ times is called a **good** integer sequence. Let $S$ be the numbe",
"description_type": "Markdown"
},
"platform": "AtCoder",
"limit": {
"time_limit": 2000,
"memory_limit": 262144
},
"difficulty": "None",
"is_remote": true,
"is_sync": true,
"sync_url": null,
"sign": "arc183_a"
},
"statements": [
{
"statement_type": "Markdown",
"content": "You are given positive integers $N$ and $K$.\nAn integer sequence of length $NK$ where each integer from $1$ to $N$ appears exactly $K$ times is called a **good** integer sequence.\nLet $S$ be the numbe...",
"is_translate": false,
"language": "English"
}
]
}