import java.math.*;
import java.util.*;

public class Main {
    static void out(boolean b) {
        if (b) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        }
    }

    static boolean Loop(String str) {
        int num = str.length();
        boolean tmp = true;
        if (num !=2) {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        }
        else {
            return false;
    }
    }
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String s = sc.next();
        boolean isLoop = true;
        isLoop = Loop(s);
        if (isLoop) {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        }
        out(isLoop);
        }
    } import java.math.*; math.* java import java.util.*; util.* java public class Main {
    static void out(boolean b) {
        if (b) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        }
    }

    static boolean Loop(String str) {
        int num = str.length();
        boolean tmp = true;
        if (num !=2) {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        }
        else {
            return false;
    }
    }
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String s = sc.next();
        boolean isLoop = true;
        isLoop = Loop(s);
        if (isLoop) {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        }
        out(isLoop);
        }
    } Main static void out(boolean b) {
        if (b) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        }
    } out {
        if (b) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        }
    } if (b) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        } b {
            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" boolean b b static boolean Loop(String str) {
        int num = str.length();
        boolean tmp = true;
        if (num !=2) {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        }
        else {
            return false;
    }
    } Loop {
        int num = str.length();
        boolean tmp = true;
        if (num !=2) {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        }
        else {
            return false;
    }
    } int num = str.length(); num str.length() str.length str boolean tmp = true; tmp true if (num !=2) {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        }
        else {
            return false;
    } num !=2 num 2 {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        } for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            } int i = 0; int i = 0; i 0 i < (num - 1) / 2 i (num - 1) / 2 (num - 1) num 1 2 i++ i++ i {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            } {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            } if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                } str.charAt(i) != str.charAt(num - i - 1) str.charAt(i) str.charAt str i str.charAt(num - i - 1) str.charAt str num - i - 1 num - i - 1 num i 1 {
                    tmp = false;
                    break;
                } tmp = false tmp false break; return tmp; tmp {
            return false;
    } return false; false String str str public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String s = sc.next();
        boolean isLoop = true;
        isLoop = Loop(s);
        if (isLoop) {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        }
        out(isLoop);
        } main {
        Scanner sc = new Scanner(System.in);
        String s = sc.next();
        boolean isLoop = true;
        isLoop = Loop(s);
        if (isLoop) {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        }
        out(isLoop);
        } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String s = sc.next(); s sc.next() sc.next sc boolean isLoop = true; isLoop true isLoop = Loop(s) isLoop Loop(s) Loop s if (isLoop) {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        } isLoop {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        } isLoop = Loop(s.substring(0, (s.length() - 1 / 2 ))) isLoop Loop(s.substring(0, (s.length() - 1 / 2 ))) Loop s.substring(0, (s.length() - 1 / 2 )) s.substring s 0 (s.length() - 1 / 2 ) s.length() s.length s 1 / 2 1 2 if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            } isLoop {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            } isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 )) isLoop Loop(s.substring((s.length() + 3 )/ 2 -1 )) Loop s.substring((s.length() + 3 )/ 2 -1 ) s.substring s (s.length() + 3 )/ 2 -1 (s.length() + 3 )/ 2 (s.length() + 3 ) s.length() s.length s 3 2 1 out(isLoop) out isLoop String[] args args public class Main {
    static void out(boolean b) {
        if (b) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        }
    }

    static boolean Loop(String str) {
        int num = str.length();
        boolean tmp = true;
        if (num !=2) {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        }
        else {
            return false;
    }
    }
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String s = sc.next();
        boolean isLoop = true;
        isLoop = Loop(s);
        if (isLoop) {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        }
        out(isLoop);
        }
    } public class Main {
    static void out(boolean b) {
        if (b) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        }
    }

    static boolean Loop(String str) {
        int num = str.length();
        boolean tmp = true;
        if (num !=2) {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        }
        else {
            return false;
    }
    }
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String s = sc.next();
        boolean isLoop = true;
        isLoop = Loop(s);
        if (isLoop) {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        }
        out(isLoop);
        }
    } Main
import java.math.*;
import java.util.*;

public class Main {
    static void out(boolean b) {
        if (b) {
            System.out.println("Yes");
        } else {
            System.out.println("No");
        }
    }

    static boolean Loop(String str) {
        int num = str.length();
        boolean tmp = true;
        if (num !=2) {
            for (int i = 0; i < (num - 1) / 2; i++) {
                if (str.charAt(i) != str.charAt(num - i - 1)) {
                    tmp = false;
                    break;
                }
            }
            return tmp;
        }
        else {
            return false;
    }
    }
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String s = sc.next();
        boolean isLoop = true;
        isLoop = Loop(s);
        if (isLoop) {
            isLoop = Loop(s.substring(0, (s.length() - 1 / 2 )));
            if (isLoop) {
                isLoop = Loop(s.substring((s.length() + 3 )/ 2 -1 ));
            }
        }
        out(isLoop);
        }
    }