#include <bits/stdc++.h>
using namespace std;
int main() {
  int T, n;
  string word;
  for (scanf("%d", &T); T--;) {
    scanf("%d", &n);
    cin >> word;
    bool pos = true;
    for (int i = 0, j = n - 1; i < n / 2; i++, j--) {
      if (word[i] == word[j] || word[i] - 1 == word[j] + 1 ||
          word[i] + 1 == word[j] - 1)
        continue;
      else
        pos = false;
    }
    if (pos)
      cout << "YES\n";
    else
      cout << "NO\n";
  }
  return 0;
}
