#include <bits/stdc++.h>
using namespace std;
char a[111111];
int s;
int main() {
  gets(a);
  for (int i = 0, j = strlen(a) - 1; i < strlen(a) / 2 && j >= strlen(a) / 2;
       i++, j--)
    if ((a[i] == 'b' && a[j] == 'd') || (a[i] == 'd' && a[j] == 'b') ||
        (a[i] == 'p' && a[j] == 'q') || (a[i] == 'q' && a[j] == 'p'))
      s++;
  if (s == strlen(a) / 2)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
