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;
int64_t T = 1;
int32_t main() {
  clock_t START = clock();
  int64_t N;
  while (T--) {
    string s;
    cin >> s;
    bool ok = true;
    for (int64_t i = 2; i < s.length(); i++) {
      char a = s[i - 2];
      char b = s[i - 1];
      int64_t sum = (int64_t(a) + int64_t(b)) % 26;
      char c = char(sum + 65);
      if (c != s[i]) {
        ok = false;
        break;
      }
    }
    if (ok)
      cout << "YES" << endl;
    else
      cout << "NO" << endl;
  }
  clock_t END = clock();
  cerr << "Time = " << fixed << setprecision(4)
       << double(END - START) / double(CLOCKS_PER_SEC) << endl;
}