#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    int sum = 1;
    int x[30] = {0};
    int n;
    cin >> n;
    for (int i = 1; i <= 26; i++) x[i] = 0;
    for (int i = 1; i <= n; i++) {
      string a;
      cin >> a;
      int l = a.size();
      for (int i = 0; i < l; i++) {
        x[a[i] - 'a' + 1]++;
      }
    }
    for (int i = 1; i <= 26; i++) {
      if (x[i] % n != 0) {
        sum = 0;
        break;
      }
    }
    if (sum == 0) {
      cout << "No" << endl;
    } else
      cout << "Yes" << endl;
  }
  return 0;
}
