#include <bits/stdc++.h>
using namespace std;
const int Range = 10000001;
bool Primes[Range] = {false};
void IsPrime() {
  Primes[0] = true;
  Primes[1] = true;
  for (int i = 2; i <= Range; i++) {
    if (!Primes[i]) {
      for (int j = i; (long long)j * i <= Range; j++) {
        Primes[j * i] = true;
      }
    }
  }
}
bool IsPrimeDIV(long long p) {
  bool check = false;
  for (int i = 2; i < sqrt(p); i++)
    if (p % i == 0) {
      check = true;
      break;
    }
  if (check == true) {
    return false;
  } else if (check == false) {
    return true;
  }
}
int main() {
  string sample;
  bool precheck = true;
  cin >> sample;
  for (int i = 0; i < sample.size(); i++) {
    if (sample[i] == 'B') {
      precheck = false;
    } else if (sample[i] == 'C') {
      precheck = false;
    } else if (sample[i] == 'D') {
      precheck = false;
    } else if (sample[i] == 'E') {
      precheck = false;
    } else if (sample[i] == 'F') {
      precheck = false;
    } else if (sample[i] == 'G') {
      precheck = false;
    } else if (sample[i] == 'J') {
      precheck = false;
    } else if (sample[i] == 'K') {
      precheck = false;
    } else if (sample[i] == 'L') {
      precheck = false;
    } else if (sample[i] == 'N') {
      precheck = false;
    } else if (sample[i] == 'P') {
      precheck = false;
    } else if (sample[i] == 'Q') {
      precheck = false;
    } else if (sample[i] == 'R') {
      precheck = false;
    } else if (sample[i] == 'S') {
      precheck = false;
    } else if (sample[i] == 'Z') {
      precheck = false;
    }
  }
  bool seccheck = true;
  for (int i = 0; i < sample.size(); i++) {
    if (sample[i] == sample[sample.size() - 1 - i]) {
      continue;
    } else {
      seccheck = false;
    }
  }
  if (precheck == true && seccheck == true) {
    cout << "YES";
  } else {
    cout << "NO";
  }
  return 0;
}
