import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        try (Scanner sc = new Scanner(System.in)) {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        }
    }

    private static boolean isPalindrome(String s) {
        for (int l = 0, r = s.length() - 1; l < r; l++, r--) {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        }
        return true;
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        try (Scanner sc = new Scanner(System.in)) {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        }
    }

    private static boolean isPalindrome(String s) {
        for (int l = 0, r = s.length() - 1; l < r; l++, r--) {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        }
        return true;
    }
} Main public static void main(String[] args) {
        try (Scanner sc = new Scanner(System.in)) {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        }
    } main {
        try (Scanner sc = new Scanner(System.in)) {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        }
    } try (Scanner sc = new Scanner(System.in)) {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        } {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        } Scanner sc = new Scanner(System.in) Scanner sc = new Scanner(System.in) new Scanner(System.in) String S = sc.next(); S sc.next() sc.next sc int N = S.length(); N S.length() S.length S System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No") System.out.println System.out System System.out isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No" isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) isPalindrome(S) isPalindrome S isPalindrome(S.substring(0, (N - 1) / 2)) isPalindrome S.substring(0, (N - 1) / 2) S.substring S 0 (N - 1) / 2 (N - 1) N 1 2 isPalindrome(S.substring((N + 3) / 2 - 1, N)) isPalindrome S.substring((N + 3) / 2 - 1, N) S.substring S (N + 3) / 2 - 1 (N + 3) / 2 (N + 3) N 3 2 1 N "Yes" "No" String[] args args private static boolean isPalindrome(String s) {
        for (int l = 0, r = s.length() - 1; l < r; l++, r--) {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        }
        return true;
    } isPalindrome {
        for (int l = 0, r = s.length() - 1; l < r; l++, r--) {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        }
        return true;
    } for (int l = 0, r = s.length() - 1; l < r; l++, r--) {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        } int l = 0, r = s.length() - 1; int l = 0 l 0 r = s.length() - 1; r s.length() - 1 s.length() s.length s 1 l < r l r l++, r-- l++ l r-- r {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        } {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        } if (s.charAt(l) != s.charAt(r)) {
                return false;
            } s.charAt(l) != s.charAt(r) s.charAt(l) s.charAt s l s.charAt(r) s.charAt s r {
                return false;
            } return false; false return true; true String s s public class Main {
    public static void main(String[] args) {
        try (Scanner sc = new Scanner(System.in)) {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        }
    }

    private static boolean isPalindrome(String s) {
        for (int l = 0, r = s.length() - 1; l < r; l++, r--) {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        }
        return true;
    }
} public class Main {
    public static void main(String[] args) {
        try (Scanner sc = new Scanner(System.in)) {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        }
    }

    private static boolean isPalindrome(String s) {
        for (int l = 0, r = s.length() - 1; l < r; l++, r--) {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        }
        return true;
    }
} Main
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        try (Scanner sc = new Scanner(System.in)) {
            String S = sc.next();
            int N = S.length();
            System.out.println(isPalindrome(S) && isPalindrome(S.substring(0, (N - 1) / 2)) && isPalindrome(S.substring((N + 3) / 2 - 1, N)) ? "Yes" : "No");
        }
    }

    private static boolean isPalindrome(String s) {
        for (int l = 0, r = s.length() - 1; l < r; l++, r--) {
            if (s.charAt(l) != s.charAt(r)) {
                return false;
            }
        }
        return true;
    }
}
