import java.io.*;
public class Main{
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String in = br.readLine();
        int n = in.length();
        String t1 = new StringBuilder(in).reverse().toString();
        
        String s1 = in.substring(0,(n-1)/2);
        String t2 = new StringBuffer(s1).reverse().toString();
        
        String s2 = in.substring((n+3)/2-1, n);
        String t3 = new StringBuffer(s2).reverse().toString();
        
        System.out.println(s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No");
    }
} import java.io.*; io.* java public class Main{
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String in = br.readLine();
        int n = in.length();
        String t1 = new StringBuilder(in).reverse().toString();
        
        String s1 = in.substring(0,(n-1)/2);
        String t2 = new StringBuffer(s1).reverse().toString();
        
        String s2 = in.substring((n+3)/2-1, n);
        String t3 = new StringBuffer(s2).reverse().toString();
        
        System.out.println(s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No");
    }
} Main public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String in = br.readLine();
        int n = in.length();
        String t1 = new StringBuilder(in).reverse().toString();
        
        String s1 = in.substring(0,(n-1)/2);
        String t2 = new StringBuffer(s1).reverse().toString();
        
        String s2 = in.substring((n+3)/2-1, n);
        String t3 = new StringBuffer(s2).reverse().toString();
        
        System.out.println(s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No");
    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String in = br.readLine();
        int n = in.length();
        String t1 = new StringBuilder(in).reverse().toString();
        
        String s1 = in.substring(0,(n-1)/2);
        String t2 = new StringBuffer(s1).reverse().toString();
        
        String s2 = in.substring((n+3)/2-1, n);
        String t3 = new StringBuffer(s2).reverse().toString();
        
        System.out.println(s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No");
    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String in = br.readLine(); in br.readLine() br.readLine br int n = in.length(); n in.length() in.length in String t1 = new StringBuilder(in).reverse().toString(); t1 new StringBuilder(in).reverse().toString() new StringBuilder(in).reverse().toString new StringBuilder(in).reverse() new StringBuilder(in).reverse new StringBuilder(in) String s1 = in.substring(0,(n-1)/2); s1 in.substring(0,(n-1)/2) in.substring in 0 (n-1)/2 (n-1) n 1 2 String t2 = new StringBuffer(s1).reverse().toString(); t2 new StringBuffer(s1).reverse().toString() new StringBuffer(s1).reverse().toString new StringBuffer(s1).reverse() new StringBuffer(s1).reverse new StringBuffer(s1) String s2 = in.substring((n+3)/2-1, n); s2 in.substring((n+3)/2-1, n) in.substring in (n+3)/2-1 (n+3)/2 (n+3) n 3 2 1 n String t3 = new StringBuffer(s2).reverse().toString(); t3 new StringBuffer(s2).reverse().toString() new StringBuffer(s2).reverse().toString new StringBuffer(s2).reverse() new StringBuffer(s2).reverse new StringBuffer(s2) System.out.println(s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No") System.out.println System.out System System.out s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No" s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) s1.equals(t2) s1.equals s1 t2 s2.equals(t3) s2.equals s2 t3 in.equals(t1) in.equals in t1 "Yes" "No" String[] args args public class Main{
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String in = br.readLine();
        int n = in.length();
        String t1 = new StringBuilder(in).reverse().toString();
        
        String s1 = in.substring(0,(n-1)/2);
        String t2 = new StringBuffer(s1).reverse().toString();
        
        String s2 = in.substring((n+3)/2-1, n);
        String t3 = new StringBuffer(s2).reverse().toString();
        
        System.out.println(s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No");
    }
} public class Main{
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String in = br.readLine();
        int n = in.length();
        String t1 = new StringBuilder(in).reverse().toString();
        
        String s1 = in.substring(0,(n-1)/2);
        String t2 = new StringBuffer(s1).reverse().toString();
        
        String s2 = in.substring((n+3)/2-1, n);
        String t3 = new StringBuffer(s2).reverse().toString();
        
        System.out.println(s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No");
    }
} Main
import java.io.*;
public class Main{
    public static void main(String[] args) throws IOException{
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String in = br.readLine();
        int n = in.length();
        String t1 = new StringBuilder(in).reverse().toString();
        
        String s1 = in.substring(0,(n-1)/2);
        String t2 = new StringBuffer(s1).reverse().toString();
        
        String s2 = in.substring((n+3)/2-1, n);
        String t3 = new StringBuffer(s2).reverse().toString();
        
        System.out.println(s1.equals(t2)&&s2.equals(t3)&&in.equals(t1) ? "Yes" : "No");
    }
}