for _ in range(int(input())): a,list_p=list(map(int,input().split())) list_p.sort() list_p.reverse() print(*list_p)