Feedback | If you notice incorrect translations in Contester, please let author know.
|
|
Time limit 0/4000/4000/4000 ms. Memory limit 0/65000/65000/65000 Kb.
Difficulty Alpha
. . , , , .
: N (0 < N <= 1000) - . N (x <= |214|)
: , .
input.txt | output.txt |
5
1 1 2 2 3
|
1 1
|
12
1 1 1 1 0 0 0 -1 -1 -1 -2 -2
|
-1 -1 -1 -2 -2
|
.
|