Problem: 

Input

The input consists of a single string of uppercase letters A-Z. The length of the string is between 1 and 10 characters, inclusive.

Output

Output "YES" or "NO".

Examples

Input


GENIUS


Output


YES


Input


DOCTOR


Output


NO


Input


IRENE


Output


YES


Input


MARY


Output


NO


Input


SMARTPHONE


Output


NO


Input


REVOLVER


Output


YES


Input


HOLMES


Output


NO


Input


WATSON


Output


YES

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  string s;
  cin >> s;
  long long len = s.length();
  long long flag = 0;
  for (long long i = 2; i < len; ++i) {
    long long n_one = (s[i - 1] - 'A');
    long long n_two = (s[i - 2] - 'A');
    long long a = (s[i] - 'A');
    if (a != ((n_one + n_two) % 26)) {
      cout << "NO";
      flag = 1;
      break;
    }
  }
  if (flag == 0) {
    cout << "YES";
  }
}