cf/mirror

Shiori Miyagi and Maximum Array Score

CF
2171H2400· grandmaster4s256 MB⌨ stdin/stdout

Examples

Sample 1of 1multi-test • hover to link
Input
6
4 20
6 6
6 216
3 500
2 8
5 29
Output
7
5
19
13
3
9
2171H.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)