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.util.*;



import java.io.*;
import java.lang.*;
import java.math.BigInteger;

public class Main
{
	public static void main (String[] args) throws java.lang.Exception
	{
		Scanner sc=new Scanner(System.in);
		String x=sc.nextLine();
		if(x.length()<=2){
		    System.out.println("YES");
		    System.exit(0);
		}
		int a[]=new int[x.length()];
		for(int i=0;i<x.length();i++)
			a[i]=x.charAt(i)-'A';
		int f=a[0];
		int s=a[1];
	
		boolean c=false;
		for(int i=2;i<a.length;i++){
			
			if((f+s)%26==a[i]){
				;
			}
			else{
				c=true;
				break;
			}
			f=s;
			s=a[i];
		}
		if(c)
		System.out.println("NO");
		else
			System.out.println("YES");
		
	}
}