#include <bits/stdc++.h>
using namespace std;
int main() {
  int t, n;
  string s;
  cin >> t;
  while (t--) {
    cin >> n >> s;
    int j = n - 1, i;
    int flag = 1;
    for (i = 0; i <= j; i++, j--) {
      if (s[i] - 1 == s[j] - 1 || s[i] + 1 == s[j] + 1 ||
          s[i] + 1 == s[j] - 1 || s[i] - 1 == s[j] + 1)
        continue;
      else
        flag = 0;
    }
    if (flag == 0)
      printf("NO\n");
    else
      printf("YES\n");
  }
}
