import java.util.*;
 
public class Main {
    public static void main(String args[]){
        Scanner stdIn = new Scanner(System.in);
 
        String s = stdIn.next();
        char c[] = s.toCharArray();
        
        int quo = (s.length() - 1) / 2;
        
        String s1 = s.substring(0, quo);
        char c1[] = s1.toCharArray();
        
        //System.out.println(s1);//
        
        String s2 = s.substring((s.length() + 3) / 2 - 1, s.length());
        char c2[] = s2.toCharArray();
        
        //System.out.println(s2);//
        
        boolean flag = true;
        
        if(flag){
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        

        //int c = stdIn.nextInt();
        //int x = stdIn.nextInt();
        
        
        
        
        // for(int i = 0; i < s.length(); i++){
        //     a[i] = c[i] - 48;
        //     System.out.println(a[i]);
        // }
        //int sum = 0;
        //boolean flag = true;
        //for(int i = 0; i < s.length(); i++){
        //}
        
        if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
        
 
        //System.out.println();
        //System.out.print();
 
        stdIn.close();
    }
} import java.util.*; util.* java public class Main {
    public static void main(String args[]){
        Scanner stdIn = new Scanner(System.in);
 
        String s = stdIn.next();
        char c[] = s.toCharArray();
        
        int quo = (s.length() - 1) / 2;
        
        String s1 = s.substring(0, quo);
        char c1[] = s1.toCharArray();
        
        //System.out.println(s1);//
        
        String s2 = s.substring((s.length() + 3) / 2 - 1, s.length());
        char c2[] = s2.toCharArray();
        
        //System.out.println(s2);//
        
        boolean flag = true;
        
        if(flag){
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        

        //int c = stdIn.nextInt();
        //int x = stdIn.nextInt();
        
        
        
        
        // for(int i = 0; i < s.length(); i++){
        //     a[i] = c[i] - 48;
        //     System.out.println(a[i]);
        // }
        //int sum = 0;
        //boolean flag = true;
        //for(int i = 0; i < s.length(); i++){
        //}
        
        if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
        
 
        //System.out.println();
        //System.out.print();
 
        stdIn.close();
    }
} Main public static void main(String args[]){
        Scanner stdIn = new Scanner(System.in);
 
        String s = stdIn.next();
        char c[] = s.toCharArray();
        
        int quo = (s.length() - 1) / 2;
        
        String s1 = s.substring(0, quo);
        char c1[] = s1.toCharArray();
        
        //System.out.println(s1);//
        
        String s2 = s.substring((s.length() + 3) / 2 - 1, s.length());
        char c2[] = s2.toCharArray();
        
        //System.out.println(s2);//
        
        boolean flag = true;
        
        if(flag){
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        

        //int c = stdIn.nextInt();
        //int x = stdIn.nextInt();
        
        
        
        
        // for(int i = 0; i < s.length(); i++){
        //     a[i] = c[i] - 48;
        //     System.out.println(a[i]);
        // }
        //int sum = 0;
        //boolean flag = true;
        //for(int i = 0; i < s.length(); i++){
        //}
        
        if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
        
 
        //System.out.println();
        //System.out.print();
 
        stdIn.close();
    } main {
        Scanner stdIn = new Scanner(System.in);
 
        String s = stdIn.next();
        char c[] = s.toCharArray();
        
        int quo = (s.length() - 1) / 2;
        
        String s1 = s.substring(0, quo);
        char c1[] = s1.toCharArray();
        
        //System.out.println(s1);//
        
        String s2 = s.substring((s.length() + 3) / 2 - 1, s.length());
        char c2[] = s2.toCharArray();
        
        //System.out.println(s2);//
        
        boolean flag = true;
        
        if(flag){
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        

        //int c = stdIn.nextInt();
        //int x = stdIn.nextInt();
        
        
        
        
        // for(int i = 0; i < s.length(); i++){
        //     a[i] = c[i] - 48;
        //     System.out.println(a[i]);
        // }
        //int sum = 0;
        //boolean flag = true;
        //for(int i = 0; i < s.length(); i++){
        //}
        
        if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
        
 
        //System.out.println();
        //System.out.print();
 
        stdIn.close();
    } Scanner stdIn = new Scanner(System.in); stdIn new Scanner(System.in) String s = stdIn.next(); s stdIn.next() stdIn.next stdIn char c[] = s.toCharArray(); c s.toCharArray() s.toCharArray s int quo = (s.length() - 1) / 2; quo (s.length() - 1) / 2 (s.length() - 1) s.length() s.length s 1 2 String s1 = s.substring(0, quo); s1 s.substring(0, quo) s.substring s 0 quo char c1[] = s1.toCharArray(); c1 s1.toCharArray() s1.toCharArray s1 String s2 = s.substring((s.length() + 3) / 2 - 1, s.length()); s2 s.substring((s.length() + 3) / 2 - 1, s.length()) s.substring s (s.length() + 3) / 2 - 1 (s.length() + 3) / 2 (s.length() + 3) s.length() s.length s 3 2 1 s.length() s.length s char c2[] = s2.toCharArray(); c2 s2.toCharArray() s2.toCharArray s2 boolean flag = true; flag true if(flag){
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        } flag {
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        } for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } int i = 0; int i = 0; i 0 i < s.length() / 2 i s.length() / 2 s.length() s.length s 2 i++ i++ i {
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } {
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                } c[i] != c[s.length() - 1 - i] c[i] c i c[s.length() - 1 - i] c s.length() - 1 - i s.length() - 1 - i s.length() s.length s 1 i {
                    flag = false;
                    break;
                } flag = false flag false break; if(flag){
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        } flag {
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        } for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } int i = 0; int i = 0; i 0 i < s1.length() / 2 i s1.length() / 2 s1.length() s1.length s1 2 i++ i++ i {
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } {
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                } c1[i] != c1[s1.length() - 1 - i] c1[i] c1 i c1[s1.length() - 1 - i] c1 s1.length() - 1 - i s1.length() - 1 - i s1.length() s1.length s1 1 i {
                    flag = false;
                    break;
                } flag = false flag false break; if(flag){
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        } flag {
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        } for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } int i = 0; int i = 0; i 0 i < s2.length() / 2 i s2.length() / 2 s2.length() s2.length s2 2 i++ i++ i {
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } {
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            } if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                } c2[i] != c2[s2.length() - 1 - i] c2[i] c2 i c2[s2.length() - 1 - i] c2 s2.length() - 1 - i s2.length() - 1 - i s2.length() s2.length s2 1 i {
                    flag = false;
                    break;
                } flag = false flag false break; if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        } flag {
            System.out.println("Yes");
        } System.out.println("Yes") System.out.println System.out System System.out "Yes" {
            System.out.println("No");
        } System.out.println("No") System.out.println System.out System System.out "No" stdIn.close() stdIn.close stdIn String args[] args public class Main {
    public static void main(String args[]){
        Scanner stdIn = new Scanner(System.in);
 
        String s = stdIn.next();
        char c[] = s.toCharArray();
        
        int quo = (s.length() - 1) / 2;
        
        String s1 = s.substring(0, quo);
        char c1[] = s1.toCharArray();
        
        //System.out.println(s1);//
        
        String s2 = s.substring((s.length() + 3) / 2 - 1, s.length());
        char c2[] = s2.toCharArray();
        
        //System.out.println(s2);//
        
        boolean flag = true;
        
        if(flag){
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        

        //int c = stdIn.nextInt();
        //int x = stdIn.nextInt();
        
        
        
        
        // for(int i = 0; i < s.length(); i++){
        //     a[i] = c[i] - 48;
        //     System.out.println(a[i]);
        // }
        //int sum = 0;
        //boolean flag = true;
        //for(int i = 0; i < s.length(); i++){
        //}
        
        if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
        
 
        //System.out.println();
        //System.out.print();
 
        stdIn.close();
    }
} public class Main {
    public static void main(String args[]){
        Scanner stdIn = new Scanner(System.in);
 
        String s = stdIn.next();
        char c[] = s.toCharArray();
        
        int quo = (s.length() - 1) / 2;
        
        String s1 = s.substring(0, quo);
        char c1[] = s1.toCharArray();
        
        //System.out.println(s1);//
        
        String s2 = s.substring((s.length() + 3) / 2 - 1, s.length());
        char c2[] = s2.toCharArray();
        
        //System.out.println(s2);//
        
        boolean flag = true;
        
        if(flag){
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        

        //int c = stdIn.nextInt();
        //int x = stdIn.nextInt();
        
        
        
        
        // for(int i = 0; i < s.length(); i++){
        //     a[i] = c[i] - 48;
        //     System.out.println(a[i]);
        // }
        //int sum = 0;
        //boolean flag = true;
        //for(int i = 0; i < s.length(); i++){
        //}
        
        if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
        
 
        //System.out.println();
        //System.out.print();
 
        stdIn.close();
    }
} Main
import java.util.*;
 
public class Main {
    public static void main(String args[]){
        Scanner stdIn = new Scanner(System.in);
 
        String s = stdIn.next();
        char c[] = s.toCharArray();
        
        int quo = (s.length() - 1) / 2;
        
        String s1 = s.substring(0, quo);
        char c1[] = s1.toCharArray();
        
        //System.out.println(s1);//
        
        String s2 = s.substring((s.length() + 3) / 2 - 1, s.length());
        char c2[] = s2.toCharArray();
        
        //System.out.println(s2);//
        
        boolean flag = true;
        
        if(flag){
            for(int i = 0; i < s.length() / 2; i++){
                if(c[i] != c[s.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s1.length() / 2; i++){
                if(c1[i] != c1[s1.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        //System.out.println(flag);//
        
        if(flag){
            for(int i = 0; i < s2.length() / 2; i++){
                if(c2[i] != c2[s2.length() - 1 - i]){
                    flag = false;
                    break;
                }
            }
        }
        
        

        //int c = stdIn.nextInt();
        //int x = stdIn.nextInt();
        
        
        
        
        // for(int i = 0; i < s.length(); i++){
        //     a[i] = c[i] - 48;
        //     System.out.println(a[i]);
        // }
        //int sum = 0;
        //boolean flag = true;
        //for(int i = 0; i < s.length(); i++){
        //}
        
        if(flag){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
        
 
        //System.out.println();
        //System.out.print();
 
        stdIn.close();
    }
}