cf/mirror

Split Plus K

CF
1909D1900· candidate master1s256 MB⌨ stdin/stdout

Examples

Sample 1of 1multi-test • hover to link
Input
9
2 1
3 4
2 3
7 11
3 10
100 40 100
2 1
1 2
2 2
1 2
1 327869541
327869541
5 26250314066
439986238782 581370817372 409476934981 287439719777 737637983182
5 616753575719
321037808624 222034505841 214063039282 441536506916 464097941819
5 431813672576
393004301966 405902283416 900951084746 672201172466 518769038906
Output
3
1
4
-1
-1
0
3119
28999960732
-1
1909D.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)