N = int(input())
for _ in range(N):
    K, *L = map(int, input().split())
    L.sort(reverse=True)
    print(*L)