5 2 2 1 2 1
12 $12$ pairs of integers satisfy the conditions: $(L, R) = (1, 1), (1, 3), (1, 4), (2, 2), (2, 3), (2, 4), (3, 3), (3, 4), (3, 5), (4, 4), (4, 5), (5, 5)$.
4 4 4 4 4
4
10 1 2 1 4 3 3 3 2 2 4
47
{
"problem": {
"name": "Alone",
"description": {
"content": "You are given an integer sequence $A = (A_1, A_2, \\ldots, A_N)$. Find the number of pairs of integers $(L, R)$ that satisfy the following conditions: * $1 \\leq L \\leq R \\leq N$ * There is a numbe",
"description_type": "Markdown"
},
"platform": "AtCoder",
"limit": {
"time_limit": 3000,
"memory_limit": 262144
},
"difficulty": "None",
"is_remote": true,
"is_sync": true,
"sync_url": null,
"sign": "abc346_g"
},
"statements": [
{
"statement_type": "Markdown",
"content": "You are given an integer sequence $A = (A_1, A_2, \\ldots, A_N)$.\nFind the number of pairs of integers $(L, R)$ that satisfy the following conditions:\n\n* $1 \\leq L \\leq R \\leq N$\n* There is a numbe...",
"is_translate": false,
"language": "English"
}
]
}