#include <bits/stdc++.h>
using namespace std;
int a[30] = {0, 1, 0, 0, 0, 1, 1, 0, 1, 1, 0, 1, 1, 1,
             1, 0, 0, 0, 0, 0, 1, 0, 1, 1, 1, 1, 1},
    cnt;
string s;
int main() {
  cin >> s;
  for (int i = 0; i < s.size(); ++i) cnt += a[s[i] - 'A' + 1];
  if (cnt == s.size() || cnt == 0)
    puts("YES");
  else
    puts("NO");
}
