#include <bits/stdc++.h>
using namespace std;
int main() {
  int i, j, n, k, t, cnt, w, x;
  char s[102];
  cin >> t;
  for (j = 0; j < t; j++) {
    cnt = 0;
    cin >> n >> s;
    w = n / 2;
    for (i = 0; i < w; i++) {
      x = abs(s[i] - s[n - 1]);
      if ((s[i] == s[n - 1]) || x == 2) {
        cnt++;
        n--;
      } else
        break;
    }
    if (cnt == w)
      cout << "YES" << endl;
    else
      cout << "NO" << endl;
  }
  return 0;
}
