Vupsen, Pupsen and 0 solution codeforces
Vupsen and Pupsen were gifted an integer array. Since Vupsen doesn’t like the number, he threw away all numbers equal to from the array. As a result, he got an array of length .
Pupsen, on the contrary, likes the number the array . Also, the numbers in that array must not be huge, so must not contain numbers equal to the sum of their absolute values cannot exceed . Please help Vupsen to find any such array !and he got upset when he saw the array without zeroes. To cheer Pupsen up, Vupsen decided to come up with another array of length such that . Since Vupsen doesn’t like number ,
The first line contains a single integer( ) — the number of test cases. The next lines contain the description of test cases. The description of each test case consists of two lines.
The first line of each test case contains a single integer( ) — the length of the array.
The second line containsintegers ( , ) — the elements of the array .
It is guaranteed that the sum ofover all test cases does not exceed .
For each test case printintegers — elements of the array ( , , ).
It can be shown that the answer always exists.
3 2 5 5 5 5 -2 10 -9 4 7 1 2 3 4 5 6 7
1 -1 -1 5 1 -1 -1 -10 2 2 -3 5 -1 -1
In the first test case,. You could also print , for example, since
In the second test case,.