# Jiggly Puff solution codechef

## Jiggly Puff solution codechef

Jigglypuff is a pokemon that loves to sing. But listening to her song induced sleep. To prevent her from singing, Misty gives her an array of nn integer and multiplies each element with its index and ended up sorting this new array. Now she gave Jigglypuff new array and challenged her to find any array which if followed the steps would lead to the given array.

Help poor JigglyPuff solve this problem and save time to show her real talent.

Note: If there are multiple possible arrays, print any and test cases are such that at least one solution always exists.

### Input:Jiggly Puff solution codechef

• First line will contain TT, number of testcases. Then the testcases follow.
• First line of each testcase contains of a single integer NN, length of array.
• Next line contains a sorted array of length NNA1,A2,....ANA1,A2,….AN

### Output: Jiggly Puff solution codechef

For each testcase, output in a single line answer containing NN integers

### Constraints Jiggly Puff solution codechef

• 1T10001≤T≤1000
• 1N10001≤N≤1000
• 1Ai1051≤Ai≤105
• Sum of NN overall test cases does not exceed 31053∗105

2
4
1 4 9 16
3
2 3 6

1 2 3 4
3 1 2

### EXPLANATION:

Here, if we multiply elements of output array and sort, we will get the input array. For second test case 22 33 11 is also a valid answer.