#include <bits/stdc++.h>
int main() {
  int t, i;
  scanf("%d", &t);
  for (i = 0; i < t; i++) {
    int n;
    scanf("%d", &n);
    int j = n, k, l, m, o, p, a[n];
    for (k = 0; k < n; k++) {
      scanf("%d", &a[k]);
    }
    for (l = 0; l < n; l++) {
      for (m = l + 1; m < n; m++) {
        if (a[m] > a[l]) {
          o = a[l];
          a[l] = a[m];
          a[m] = o;
        } else
          continue;
      }
    }
    for (p = 0; p < n; p++) {
      printf("%d ", a[p]);
    }
    printf("\n");
  }
  return 0;
}
