


Input:
‘ARR’ = [-6,-3, 2, 1, 5]
If we take a square of each element then the array/list will become [36, 9, 4, 1, 25].
Then the sorted array/list will be [1, 4, 9, 25, 36].
Output :
[1, 4, 9, 25, 36].
The first line of input contains a single integer ‘T’, representing the number of test cases.
Then the ‘T’ test cases follow.
The first line of each test case contains a single integer ‘N’ denoting the size of ‘ARR’.
The second line contains ‘N’ space-separated distinct integers denoting the array elements.
For each test case, print the array elements separated by a single space.
The output of every test case will be printed in a separate line.
You don’t have to print anything, it has already been taken care of. Just implement the given function.
1 <= T <=100
1 <= N <= 10^4
-10^4 <= ‘ARR[i]’ <= 10^4
Where 'ARR[i]' denotes the value of 'ARR' at index 'i'.
Time limit: 1 sec
Algorithm:
Algorithm: