import java.util.HashMap;
import java.util.Scanner;

public class Main {


    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

	    Result result = execute(sc.nextLine());
        System.out.println(result);
    }

    public static Result execute(String str){
        if(!isPalindrone(str)){
            return Result.No;
        }
        int length = str.length();
        String firstHalf = str.substring(0,(length - 1)/2);
        if(!isPalindrone(firstHalf)){
            return Result.No;
        }
        String lastHalf = str.substring((length + 1)/2);
        if(!isPalindrone(lastHalf)){
            return Result.No;
        }
        return Result.Yes;
    }


    private static boolean isPalindrone(String str) {
        int length = str.length();
        if(length == 1){
            return true;
        }
        for(int i = 0; i< (length+1) / 2 ; i++){
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        }
        
        return true;
    }

    public static enum Result{
        Yes,
        No;
    }
} import java.util.HashMap; HashMap java.util import java.util.Scanner; Scanner java.util public class Main {


    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

	    Result result = execute(sc.nextLine());
        System.out.println(result);
    }

    public static Result execute(String str){
        if(!isPalindrone(str)){
            return Result.No;
        }
        int length = str.length();
        String firstHalf = str.substring(0,(length - 1)/2);
        if(!isPalindrone(firstHalf)){
            return Result.No;
        }
        String lastHalf = str.substring((length + 1)/2);
        if(!isPalindrone(lastHalf)){
            return Result.No;
        }
        return Result.Yes;
    }


    private static boolean isPalindrone(String str) {
        int length = str.length();
        if(length == 1){
            return true;
        }
        for(int i = 0; i< (length+1) / 2 ; i++){
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        }
        
        return true;
    }

    public static enum Result{
        Yes,
        No;
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

	    Result result = execute(sc.nextLine());
        System.out.println(result);
    } main {
        Scanner sc = new Scanner(System.in);

	    Result result = execute(sc.nextLine());
        System.out.println(result);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) Result result = execute(sc.nextLine()); result execute(sc.nextLine()) execute sc.nextLine() sc.nextLine sc System.out.println(result) System.out.println System.out System System.out result String[] args args public static Result execute(String str){
        if(!isPalindrone(str)){
            return Result.No;
        }
        int length = str.length();
        String firstHalf = str.substring(0,(length - 1)/2);
        if(!isPalindrone(firstHalf)){
            return Result.No;
        }
        String lastHalf = str.substring((length + 1)/2);
        if(!isPalindrone(lastHalf)){
            return Result.No;
        }
        return Result.Yes;
    } execute {
        if(!isPalindrone(str)){
            return Result.No;
        }
        int length = str.length();
        String firstHalf = str.substring(0,(length - 1)/2);
        if(!isPalindrone(firstHalf)){
            return Result.No;
        }
        String lastHalf = str.substring((length + 1)/2);
        if(!isPalindrone(lastHalf)){
            return Result.No;
        }
        return Result.Yes;
    } if(!isPalindrone(str)){
            return Result.No;
        } !isPalindrone(str) isPalindrone(str) isPalindrone str {
            return Result.No;
        } return Result.No; Result.No Result Result.No int length = str.length(); length str.length() str.length str String firstHalf = str.substring(0,(length - 1)/2); firstHalf str.substring(0,(length - 1)/2) str.substring str 0 (length - 1)/2 (length - 1) length 1 2 if(!isPalindrone(firstHalf)){
            return Result.No;
        } !isPalindrone(firstHalf) isPalindrone(firstHalf) isPalindrone firstHalf {
            return Result.No;
        } return Result.No; Result.No Result Result.No String lastHalf = str.substring((length + 1)/2); lastHalf str.substring((length + 1)/2) str.substring str (length + 1)/2 (length + 1) length 1 2 if(!isPalindrone(lastHalf)){
            return Result.No;
        } !isPalindrone(lastHalf) isPalindrone(lastHalf) isPalindrone lastHalf {
            return Result.No;
        } return Result.No; Result.No Result Result.No return Result.Yes; Result.Yes Result Result.Yes String str str private static boolean isPalindrone(String str) {
        int length = str.length();
        if(length == 1){
            return true;
        }
        for(int i = 0; i< (length+1) / 2 ; i++){
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        }
        
        return true;
    } isPalindrone {
        int length = str.length();
        if(length == 1){
            return true;
        }
        for(int i = 0; i< (length+1) / 2 ; i++){
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        }
        
        return true;
    } int length = str.length(); length str.length() str.length str if(length == 1){
            return true;
        } length == 1 length 1 {
            return true;
        } return true; true for(int i = 0; i< (length+1) / 2 ; i++){
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        } int i = 0; int i = 0; i 0 i< (length+1) / 2 i (length+1) / 2 (length+1) length 1 2 i++ i++ i {
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        } {
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        } if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            } str.charAt(i) != str.charAt(length - i - 1) str.charAt(i) str.charAt str i str.charAt(length - i - 1) str.charAt str length - i - 1 length - i - 1 length i 1 {
                return false;
            } return false; false return true; true String str str public static enum Result{
        Yes,
        No;
    } Result Yes Yes No No import java.util.HashMap;
import ja import java.util.HashMap;
import java.util.Scanner;

public class Main {


    public static void public class Main {


    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

	    Result result = execute(sc.nextLine());
        System.out.println(result);
    }

    public static Result execute(String str){
        if(!isPalindrone(str)){
            return Result.No;
        }
        int length = str.length();
        String firstHalf = str.substring(0,(length - 1)/2);
        if(!isPalindrone(firstHalf)){
            return Result.No;
        }
        String lastHalf = str.substring((length + 1)/2);
        if(!isPalindrone(lastHalf)){
            return Result.No;
        }
        return Result.Yes;
    }


    private static boolean isPalindrone(String str) {
        int length = str.length();
        if(length == 1){
            return true;
        }
        for(int i = 0; i< (length+1) / 2 ; i++){
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        }
        
        return true;
    }

    public static enum Result{
        Yes,
        No;
    }
} public class Main {


    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

	    Result result = execute(sc.nextLine());
        System.out.println(result);
    }

    public static Result execute(String str){
        if(!isPalindrone(str)){
            return Result.No;
        }
        int length = str.length();
        String firstHalf = str.substring(0,(length - 1)/2);
        if(!isPalindrone(firstHalf)){
            return Result.No;
        }
        String lastHalf = str.substring((length + 1)/2);
        if(!isPalindrone(lastHalf)){
            return Result.No;
        }
        return Result.Yes;
    }


    private static boolean isPalindrone(String str) {
        int length = str.length();
        if(length == 1){
            return true;
        }
        for(int i = 0; i< (length+1) / 2 ; i++){
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        }
        
        return true;
    }

    public static enum Result{
        Yes,
        No;
    }
} Main
import java.util.HashMap;
import java.util.Scanner;

public class Main {


    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

	    Result result = execute(sc.nextLine());
        System.out.println(result);
    }

    public static Result execute(String str){
        if(!isPalindrone(str)){
            return Result.No;
        }
        int length = str.length();
        String firstHalf = str.substring(0,(length - 1)/2);
        if(!isPalindrone(firstHalf)){
            return Result.No;
        }
        String lastHalf = str.substring((length + 1)/2);
        if(!isPalindrone(lastHalf)){
            return Result.No;
        }
        return Result.Yes;
    }


    private static boolean isPalindrone(String str) {
        int length = str.length();
        if(length == 1){
            return true;
        }
        for(int i = 0; i< (length+1) / 2 ; i++){
            if(str.charAt(i) != str.charAt(length - i - 1)){
                return false;
            }
        }
        
        return true;
    }

    public static enum Result{
        Yes,
        No;
    }
}
