#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long n;
  cin >> n;
  vector<long long> vec(n);
  long long great = 1;
  for (long long i = 0; i < n; i++) {
    cin >> vec[i];
    great = max(great, vec[i]);
  }
  string temp = "";
  for (long long i = 0; i < great; i++) temp += 'a';
  vector<string> ans;
  ans.push_back(temp);
  for (long long i = 0; i < n; i++) {
    string prev = ans[ans.size() - 1];
    string next = "";
    long long k = 0;
    for (long long j = 0; j < vec[i]; j++) {
      next += prev[j];
      k++;
    }
    if (next.length() < great) {
      next += (char)('a' + (prev[k] - 'a' + 1) % 26);
      for (long long j = k + 1; j < great; j++) next += prev[j];
    }
    ans.push_back(next);
  }
  for (long long i = 0; i < ans.size(); i++) cout << ans[i] << "\n";
}
int32_t main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long t;
  cin >> t;
  while (t--) {
    solve();
  }
}
