#include <bits/stdc++.h>
using namespace std;
const int mxn = 1e6;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int t = 1;
  cin >> t;
  while (t--) {
    int i, j, k, n, m;
    cin >> n;
    vector<int> a(n);
    for (i = 0; i < n; i++) cin >> a[i];
    vector<int> ans;
    ans.emplace_back(1);
    k = 2;
    vector<int> mp(2 * mxn + 1, 0);
    for (i = 0; i < n; i++) mp[a[i] + 1] = 1;
    while (ans.size() < n && k <= mxn) {
      int f1 = 1;
      for (i = 0; i < n; i++)
        if (mp[a[i] + k] == 1) {
          f1 = 0;
          break;
        }
      if (f1) {
        for (i = 0; i < n; i++) mp[a[i] + k] = 1;
        ans.emplace_back(k++);
      } else
        k++;
    }
    if (ans.size() == n) {
      cout << "YES\n";
      for (auto i : ans) cout << i << " ";
      cout << "\n";
    } else
      cout << "NO\n";
  }
  return 0;
}
