#include <bits/stdc++.h>
using namespace std;
const int N = 1e6 + 6;
int A[N];
bool mark[N];
int main() {
  int t;
  scanf("%d", &t);
  while (t--) {
    int n;
    scanf("%d", &n);
    for (int i = 1; i <= n; ++i) {
      scanf("%d", A + i);
    }
    puts("YES");
    int p = 1;
    for (int i = 1; i <= n; ++i) {
      printf("%d%c", p, " \n"[i == n]);
      for (int j = 1; j <= n; ++j) {
        for (int k = 1; k <= n; ++k) {
          int v = p + A[j] - A[k];
          if (1 <= v and v <= 1000000) mark[v] = true;
        }
      }
      while (mark[p]) p++;
    }
    for (int i = 1; i <= 1000000; ++i) mark[i] = false;
  }
}
