#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long n;
  cin >> n;
  vector<long long> a(n);
  long long ans = 0;
  for (int i = 0; i < n; ++i) {
    cin >> a[i];
    if (a[i] > ans) ans = a[i];
  }
  if (ans == 0) ans = 1;
  vector<string> s(n + 1);
  for (int i = 0; i < ans; ++i) {
    s[0] += 'a';
  }
  for (int i = 0; i < n; ++i) {
    s[i + 1] = s[i];
    s[i + 1][a[i]] += 1;
    if (s[i + 1][a[i]] > 'z') s[i + 1][a[i]] = 'a';
  }
  for (int i = 0; i <= n; ++i) {
    cout << s[i] << endl;
  }
}
int main() {
  int t;
  cin >> t;
  while (t--) {
    solve();
  }
  return 0;
}
