cf/mirror

Same Sum Blocks (Easy)

CF
1141F11900· candidate master2s256 MB⌨ stdin/stdout
#greedy

Examples

Sample 1of 3
Input
7
4 1 2 2 1 5 3
Output
3
7 7
2 3
4 5
Sample 2of 3
Input
11
-5 -4 -3 -2 -1 0 1 2 3 4 5
Output
2
3 4
1 1
Sample 3of 3
Input
4
1 1 1 1
Output
4
4 4
1 1
2 2
3 3
1141F1.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)