cf/mirror

Index and Maximum Value

CF
2007B900· newbie1s256 MB⌨ stdin/stdout

Examples

Sample 1of 1multi-test • hover to link
Input
5
5 5
1 2 3 2 1
+ 1 3
- 2 3
+ 1 2
+ 2 4
- 6 8
5 5
1 3 3 4 5
+ 1 4
+ 2 3
- 4 5
- 3 3
- 2 6
5 5
1 1 1 1 1
+ 2 3
- 4 5
+ 1 6
- 2 5
+ 1 8
1 1
1
- 1 1
1 1
1000000000
+ 1000000000 1000000000
Output
4 4 4 5 5
5 5 4 4 3
1 1 2 1 2
0
1000000001
2007B.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)