4 2 10 1 5 2 1 3 3 4 2 2 10 1 0 4 0 3 1 2 0 3 0
5 6 8 8 15 13 13 11 1 0 In this input, $N=4$ and $K=2$. $Q=10$ updates are applied. * The $1$\-st update makes $A=(5, 0,0,0)$. Now, $f(A)=5$. * The $2$\-nd update makes $A=(5, 1,0,0)$. Now, $f(A)=6$. * The $3$\-rd update makes $A=(5, 1,3,0)$. Now, $f(A)=8$. * The $4$\-th update makes $A=(5, 1,3,2)$. Now, $f(A)=8$. * The $5$\-th update makes $A=(5,10,3,2)$. Now, $f(A)=15$. * The $6$\-th update makes $A=(0,10,3,2)$. Now, $f(A)=13$. * The $7$\-th update makes $A=(0,10,3,0)$. Now, $f(A)=13$. * The $8$\-th update makes $A=(0,10,1,0)$. Now, $f(A)=11$. * The $9$\-th update makes $A=(0, 0,1,0)$. Now, $f(A)=1$. * The $10$\-th update makes $A=(0, 0,0,0)$. Now, $f(A)=0$.
{
"problem": {
"name": "Best Performances",
"description": {
"content": "We have a sequence $A=(A_1,A_2,\\dots,A_N)$ of length $N$. Initially, all the terms are $0$. Using an integer $K$ given in the input, we define a function $f(A)$ as follows: * Let $B$ be the seque",
"description_type": "Markdown"
},
"platform": "AtCoder",
"limit": {
"time_limit": 6000,
"memory_limit": 262144
},
"difficulty": "None",
"is_remote": true,
"is_sync": true,
"sync_url": null,
"sign": "abc306_e"
},
"statements": [
{
"statement_type": "Markdown",
"content": "We have a sequence $A=(A_1,A_2,\\dots,A_N)$ of length $N$. Initially, all the terms are $0$. \nUsing an integer $K$ given in the input, we define a function $f(A)$ as follows:\n\n* Let $B$ be the seque...",
"is_translate": false,
"language": "English"
}
]
}