#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    int arr[n];
    for (int i = 0; i < n; i++) cin >> arr[i];
    char mat[n + 1][52];
    memset(mat, 'a', sizeof(mat));
    for (int i = 1; i <= n; i++) {
      int x = arr[i - 1];
      int j;
      for (j = 0; j < x; j++) {
        mat[i][j] = mat[i - 1][j];
      }
      if (mat[i - 1][x] == 'a') {
        mat[i][x] = 'x';
      } else if (mat[i - 1][x] == 'x') {
        mat[i][x] = 'a';
      }
    }
    for (int i = 0; i <= n; i++) {
      for (int j = 0; j <= 51; j++) cout << mat[i][j];
      cout << endl;
    }
  }
  return 0;
}
