#include <bits/stdc++.h>
using namespace std;
using namespace std;
inline int in() {
  int x = 0, c;
  for (; (unsigned int)((c = getchar()) - '0') >= 10;) {
    if (c == '-') return -in();
    if (!~c) throw ~0;
  }
  do {
    x = (x << 3) + (x << 1) + (c ^ 48);
  } while ((unsigned int)((c = getchar()) ^ 48) < 10);
  return x;
}
inline int gcd(int a, int b) {
  if (a > b) swap(a, b);
  return a == 0 ? b : gcd(b % a, a);
}
inline int lcm(int a, int b) { return a * b / gcd(a, b); }
using namespace std;
int T, N;
string second;
bool valid(char a, char b) {
  if (a == b) return true;
  return a - 1 == b - 1 || a - 1 == b + 1 || a + 1 == b - 1 || a + 1 == b + 1;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin >> T;
  while (T--) {
    cin >> N >> second;
    second = " " + second;
    bool res = false;
    for (int i = 1; i <= (N >> 1); i++)
      if (!valid(second[i], second[N + 1 - i])) {
        puts("NO");
        res = true;
        break;
      }
    if (!res) puts("YES");
  }
  return 0;
}
