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 JAVA):

Solution:
import java.io.*;
import java.math.*;
import java.security.*;
import java.text.*;
import java.util.*;
import java.util.concurrent.*;
import java.util.regex.*;

public class Solution {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        String s=sc.next();
        if(s.length()>10||s.length()<1)
        {
            System.out.println("NO");
        }
        else
        {
            boolean b=true;
            for(int i=2;i<s.length();i++)
            {
                int a1=s.charAt(i-2)-65;
                int a2=s.charAt(i-1)-65;
                int a3=s.charAt(i)-65;
                if(a3==(a1+a2)%26)
                {

                }
                else
                {
                    b=false;
                    break;
                }
            }
            if(b)
                System.out.println("YES");
            else
                System.out.println("NO");
        }

    }
}