#include <bits/stdc++.h>
using namespace std;
string d = "YES", s, l = "BCDEFGJKLNPQRSZ";
map<char, bool> q;
int i;
int main() {
  for (i = 0; i <= l.size() - 1; i++) q[l[i]] = true;
  cin >> s;
  if (s.size() % 2 == 0) {
    for (i = 0; i <= s.size() / 2 - 1; i++) {
      if (q[s[i]] || s[i] != s[s.size() - 1 - i]) d = "NO";
    }
  }
  if (s.size() % 2 == 1) {
    for (i = 0; i <= (s.size() - 1) / 2; i++) {
      if (q[s[i]] || s[i] != s[s.size() - 1 - i]) d = "NO";
    }
  }
  cout << d;
  return 0;
}
