cf/mirror

Directional Increase

CF
1693A1300· pupil1s256 MB⌨ stdin/stdout
#greedy

Examples

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