import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scn = new Scanner(System.in);
        String S = scn.nextLine();
        int N = S.length();
        
        String str_before = S.substring(0,(N-1)/2);
        String str_after = S.substring((N+2)/2,N);
        StringBuffer hoge = new StringBuffer(str_before);
        String str = hoge.reverse().toString();
        if(str_after.equals(str) && str_after.equals(str_before)) System.out.println("Yes");
        else System.out.println("No");
        
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scn = new Scanner(System.in);
        String S = scn.nextLine();
        int N = S.length();
        
        String str_before = S.substring(0,(N-1)/2);
        String str_after = S.substring((N+2)/2,N);
        StringBuffer hoge = new StringBuffer(str_before);
        String str = hoge.reverse().toString();
        if(str_after.equals(str) && str_after.equals(str_before)) System.out.println("Yes");
        else System.out.println("No");
        
    }
} Main public static void main(String[] args) throws Exception {
        
        Scanner scn = new Scanner(System.in);
        String S = scn.nextLine();
        int N = S.length();
        
        String str_before = S.substring(0,(N-1)/2);
        String str_after = S.substring((N+2)/2,N);
        StringBuffer hoge = new StringBuffer(str_before);
        String str = hoge.reverse().toString();
        if(str_after.equals(str) && str_after.equals(str_before)) System.out.println("Yes");
        else System.out.println("No");
        
    } main {
        
        Scanner scn = new Scanner(System.in);
        String S = scn.nextLine();
        int N = S.length();
        
        String str_before = S.substring(0,(N-1)/2);
        String str_after = S.substring((N+2)/2,N);
        StringBuffer hoge = new StringBuffer(str_before);
        String str = hoge.reverse().toString();
        if(str_after.equals(str) && str_after.equals(str_before)) System.out.println("Yes");
        else System.out.println("No");
        
    } Scanner scn = new Scanner(System.in); scn new Scanner(System.in) String S = scn.nextLine(); S scn.nextLine() scn.nextLine scn int N = S.length(); N S.length() S.length S String str_before = S.substring(0,(N-1)/2); str_before S.substring(0,(N-1)/2) S.substring S 0 (N-1)/2 (N-1) N 1 2 String str_after = S.substring((N+2)/2,N); str_after S.substring((N+2)/2,N) S.substring S (N+2)/2 (N+2) N 2 2 N StringBuffer hoge = new StringBuffer(str_before); hoge new StringBuffer(str_before) String str = hoge.reverse().toString(); str hoge.reverse().toString() hoge.reverse().toString hoge.reverse() hoge.reverse hoge if(str_after.equals(str) && str_after.equals(str_before)) System.out.println("Yes");
        else System.out.println("No"); str_after.equals(str) && str_after.equals(str_before) str_after.equals(str) str_after.equals str_after str str_after.equals(str_before) str_after.equals str_after str_before System.out.println("Yes") System.out.println System.out System System.out "Yes" System.out.println("No") System.out.println System.out System System.out "No" String[] args args public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scn = new Scanner(System.in);
        String S = scn.nextLine();
        int N = S.length();
        
        String str_before = S.substring(0,(N-1)/2);
        String str_after = S.substring((N+2)/2,N);
        StringBuffer hoge = new StringBuffer(str_before);
        String str = hoge.reverse().toString();
        if(str_after.equals(str) && str_after.equals(str_before)) System.out.println("Yes");
        else System.out.println("No");
        
    }
} public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scn = new Scanner(System.in);
        String S = scn.nextLine();
        int N = S.length();
        
        String str_before = S.substring(0,(N-1)/2);
        String str_after = S.substring((N+2)/2,N);
        StringBuffer hoge = new StringBuffer(str_before);
        String str = hoge.reverse().toString();
        if(str_after.equals(str) && str_after.equals(str_before)) System.out.println("Yes");
        else System.out.println("No");
        
    }
} Main
import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner scn = new Scanner(System.in);
        String S = scn.nextLine();
        int N = S.length();
        
        String str_before = S.substring(0,(N-1)/2);
        String str_after = S.substring((N+2)/2,N);
        StringBuffer hoge = new StringBuffer(str_before);
        String str = hoge.reverse().toString();
        if(str_after.equals(str) && str_after.equals(str_before)) System.out.println("Yes");
        else System.out.println("No");
        
    }
}
