
import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner scn  = new Scanner(System.in);
        strong_palindrome(scn.next());
    }
    static  void  strong_palindrome(String word){

        if(palindrome(word) != word){
            System.out.println("No");
            return;
        }
        String fp = word.substring(0, (word.length()-1)/2);
        String sp = word.substring((word.length()-1)/2+1);
        if(palindrome(fp) != fp || palindrome(sp) != sp){
            System.out.println("No");
            return;
        }
        System.out.println("Yes");

    }
    static String palindrome(String word){
        for(int i = word.length()-1; i >= 0; i--){
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        }
        return  word;
    }

} import java.util.Scanner; Scanner java.util public class Main {

    public static void main(String[] args) {
        Scanner scn  = new Scanner(System.in);
        strong_palindrome(scn.next());
    }
    static  void  strong_palindrome(String word){

        if(palindrome(word) != word){
            System.out.println("No");
            return;
        }
        String fp = word.substring(0, (word.length()-1)/2);
        String sp = word.substring((word.length()-1)/2+1);
        if(palindrome(fp) != fp || palindrome(sp) != sp){
            System.out.println("No");
            return;
        }
        System.out.println("Yes");

    }
    static String palindrome(String word){
        for(int i = word.length()-1; i >= 0; i--){
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        }
        return  word;
    }

} Main public static void main(String[] args) {
        Scanner scn  = new Scanner(System.in);
        strong_palindrome(scn.next());
    } main {
        Scanner scn  = new Scanner(System.in);
        strong_palindrome(scn.next());
    } Scanner scn  = new Scanner(System.in); scn new Scanner(System.in) strong_palindrome(scn.next()) strong_palindrome scn.next() scn.next scn String[] args args static  void  strong_palindrome(String word){

        if(palindrome(word) != word){
            System.out.println("No");
            return;
        }
        String fp = word.substring(0, (word.length()-1)/2);
        String sp = word.substring((word.length()-1)/2+1);
        if(palindrome(fp) != fp || palindrome(sp) != sp){
            System.out.println("No");
            return;
        }
        System.out.println("Yes");

    } strong_palindrome {

        if(palindrome(word) != word){
            System.out.println("No");
            return;
        }
        String fp = word.substring(0, (word.length()-1)/2);
        String sp = word.substring((word.length()-1)/2+1);
        if(palindrome(fp) != fp || palindrome(sp) != sp){
            System.out.println("No");
            return;
        }
        System.out.println("Yes");

    } if(palindrome(word) != word){
            System.out.println("No");
            return;
        } palindrome(word) != word palindrome(word) palindrome word word {
            System.out.println("No");
            return;
        } System.out.println("No") System.out.println System.out System System.out "No" return; String fp = word.substring(0, (word.length()-1)/2); fp word.substring(0, (word.length()-1)/2) word.substring word 0 (word.length()-1)/2 (word.length()-1) word.length() word.length word 1 2 String sp = word.substring((word.length()-1)/2+1); sp word.substring((word.length()-1)/2+1) word.substring word (word.length()-1)/2+1 (word.length()-1)/2 (word.length()-1) word.length() word.length word 1 2 1 if(palindrome(fp) != fp || palindrome(sp) != sp){
            System.out.println("No");
            return;
        } palindrome(fp) != fp || palindrome(sp) != sp palindrome(fp) != fp palindrome(fp) palindrome fp fp palindrome(sp) != sp palindrome(sp) palindrome sp sp {
            System.out.println("No");
            return;
        } System.out.println("No") System.out.println System.out System System.out "No" return; System.out.println("Yes") System.out.println System.out System System.out "Yes" String word word static String palindrome(String word){
        for(int i = word.length()-1; i >= 0; i--){
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        }
        return  word;
    } palindrome {
        for(int i = word.length()-1; i >= 0; i--){
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        }
        return  word;
    } for(int i = word.length()-1; i >= 0; i--){
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        } int i = word.length()-1; int i = word.length()-1; i word.length()-1 word.length() word.length word 1 i >= 0 i 0 i-- i-- i {
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        } {
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        } if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            } word.charAt(i) != word.charAt(word.length()-1-i) word.charAt(i) word.charAt word i word.charAt(word.length()-1-i) word.charAt word word.length()-1-i word.length()-1-i word.length() word.length word 1 i {
                return "";
            } return ""; "" return  word; word String word word public class Main {

    public static void main(String[] args) {
        Scanner scn  = new Scanner(System.in);
        strong_palindrome(scn.next());
    }
    static  void  strong_palindrome(String word){

        if(palindrome(word) != word){
            System.out.println("No");
            return;
        }
        String fp = word.substring(0, (word.length()-1)/2);
        String sp = word.substring((word.length()-1)/2+1);
        if(palindrome(fp) != fp || palindrome(sp) != sp){
            System.out.println("No");
            return;
        }
        System.out.println("Yes");

    }
    static String palindrome(String word){
        for(int i = word.length()-1; i >= 0; i--){
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        }
        return  word;
    }

} public class Main {

    public static void main(String[] args) {
        Scanner scn  = new Scanner(System.in);
        strong_palindrome(scn.next());
    }
    static  void  strong_palindrome(String word){

        if(palindrome(word) != word){
            System.out.println("No");
            return;
        }
        String fp = word.substring(0, (word.length()-1)/2);
        String sp = word.substring((word.length()-1)/2+1);
        if(palindrome(fp) != fp || palindrome(sp) != sp){
            System.out.println("No");
            return;
        }
        System.out.println("Yes");

    }
    static String palindrome(String word){
        for(int i = word.length()-1; i >= 0; i--){
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        }
        return  word;
    }

} Main

import java.util.Scanner;

public class Main {

    public static void main(String[] args) {
        Scanner scn  = new Scanner(System.in);
        strong_palindrome(scn.next());
    }
    static  void  strong_palindrome(String word){

        if(palindrome(word) != word){
            System.out.println("No");
            return;
        }
        String fp = word.substring(0, (word.length()-1)/2);
        String sp = word.substring((word.length()-1)/2+1);
        if(palindrome(fp) != fp || palindrome(sp) != sp){
            System.out.println("No");
            return;
        }
        System.out.println("Yes");

    }
    static String palindrome(String word){
        for(int i = word.length()-1; i >= 0; i--){
            if(word.charAt(i) != word.charAt(word.length()-1-i)){
                return "";
            }
        }
        return  word;
    }

}
