import java.util.*;

public class Main {
    public static void main(String[] args){
        ABC159B();
    }
    private static void ABC159B() {
        // no comment, no error check
        final int INPUT_LINES_CNT = 1;

        ArrayList<String> inputLines = getStdInMultiLines(INPUT_LINES_CNT);

        if (inputLines.size() == 0) {
            System.out.println(0);
            return;
        }

        String outputStr;
        try {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        }
        catch (Exception ex) {
            outputStr = "No";
        }

        System.out.println(outputStr);
        return;
    }

private static int getStdInNum() {
        String line1 = getStdInSingleLine();
        if (isNumber(line1)) {
            return Integer.parseInt(line1);
        }
        return 0;
    }

    private static ArrayList<String> getStdInMultiLines() {
        int cnt = 0; 
        int max = 0;

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        }
        cin.close();
        return list;
    }
    private static ArrayList<String> getStdInMultiLines(int inputLinesCnt) {
        int cnt = 0; 

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        }
        cin.close();
        return list;
    }

    private static String getStdInSingleLine() {
        Scanner cin = new Scanner(System.in);

        for (;cin.hasNext();) {
            cin.close();
            return cin.nextLine();
        }

        cin.close();
        return "";
    }

    private static boolean isNumber(String val) {
        try {
            Integer.parseInt(val);
            return true;
        }
        catch (NumberFormatException nfex) {
            return false;
        }
    }

} import java.util.*; util.* java public class Main {
    public static void main(String[] args){
        ABC159B();
    }
    private static void ABC159B() {
        // no comment, no error check
        final int INPUT_LINES_CNT = 1;

        ArrayList<String> inputLines = getStdInMultiLines(INPUT_LINES_CNT);

        if (inputLines.size() == 0) {
            System.out.println(0);
            return;
        }

        String outputStr;
        try {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        }
        catch (Exception ex) {
            outputStr = "No";
        }

        System.out.println(outputStr);
        return;
    }

private static int getStdInNum() {
        String line1 = getStdInSingleLine();
        if (isNumber(line1)) {
            return Integer.parseInt(line1);
        }
        return 0;
    }

    private static ArrayList<String> getStdInMultiLines() {
        int cnt = 0; 
        int max = 0;

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        }
        cin.close();
        return list;
    }
    private static ArrayList<String> getStdInMultiLines(int inputLinesCnt) {
        int cnt = 0; 

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        }
        cin.close();
        return list;
    }

    private static String getStdInSingleLine() {
        Scanner cin = new Scanner(System.in);

        for (;cin.hasNext();) {
            cin.close();
            return cin.nextLine();
        }

        cin.close();
        return "";
    }

    private static boolean isNumber(String val) {
        try {
            Integer.parseInt(val);
            return true;
        }
        catch (NumberFormatException nfex) {
            return false;
        }
    }

} Main public static void main(String[] args){
        ABC159B();
    } main {
        ABC159B();
    } ABC159B() ABC159B String[] args args private static void ABC159B() {
        // no comment, no error check
        final int INPUT_LINES_CNT = 1;

        ArrayList<String> inputLines = getStdInMultiLines(INPUT_LINES_CNT);

        if (inputLines.size() == 0) {
            System.out.println(0);
            return;
        }

        String outputStr;
        try {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        }
        catch (Exception ex) {
            outputStr = "No";
        }

        System.out.println(outputStr);
        return;
    } ABC159B {
        // no comment, no error check
        final int INPUT_LINES_CNT = 1;

        ArrayList<String> inputLines = getStdInMultiLines(INPUT_LINES_CNT);

        if (inputLines.size() == 0) {
            System.out.println(0);
            return;
        }

        String outputStr;
        try {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        }
        catch (Exception ex) {
            outputStr = "No";
        }

        System.out.println(outputStr);
        return;
    } final int INPUT_LINES_CNT = 1; INPUT_LINES_CNT 1 ArrayList<String> inputLines = getStdInMultiLines(INPUT_LINES_CNT); inputLines getStdInMultiLines(INPUT_LINES_CNT) getStdInMultiLines INPUT_LINES_CNT if (inputLines.size() == 0) {
            System.out.println(0);
            return;
        } inputLines.size() == 0 inputLines.size() inputLines.size inputLines 0 {
            System.out.println(0);
            return;
        } System.out.println(0) System.out.println System.out System System.out 0 return; String outputStr; outputStr try {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        }
        catch (Exception ex) {
            outputStr = "No";
        } catch (Exception ex) {
            outputStr = "No";
        } Exception ex {
            outputStr = "No";
        } outputStr = "No" outputStr "No" {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        } List<String> inputLineList = Arrays.asList((inputLines.get(0))); inputLineList Arrays.asList((inputLines.get(0))) Arrays.asList Arrays (inputLines.get(0)) inputLines.get inputLines 0 String kaibun = inputLineList.get(0); kaibun inputLineList.get(0) inputLineList.get inputLineList 0 int len = kaibun.length(); len kaibun.length() kaibun.length kaibun String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2); sSHarfKaibun inputLineList.get(0).substring(0,len / 2) inputLineList.get(0).substring inputLineList.get(0) inputLineList.get inputLineList 0 0 len / 2 len 2 String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString(); sRHarfKaibun new StringBuilder(sSHarfKaibun).reverse().toString() new StringBuilder(sSHarfKaibun).reverse().toString new StringBuilder(sSHarfKaibun).reverse() new StringBuilder(sSHarfKaibun).reverse new StringBuilder(sSHarfKaibun) String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len); rSHarfKaibun inputLineList.get(0).substring(len / 2 + len % 2, len) inputLineList.get(0).substring inputLineList.get(0) inputLineList.get inputLineList 0 len / 2 + len % 2 len / 2 len 2 len % 2 len 2 len String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString(); rRHarfKaibun new StringBuilder(rSHarfKaibun).reverse().toString() new StringBuilder(rSHarfKaibun).reverse().toString new StringBuilder(rSHarfKaibun).reverse() new StringBuilder(rSHarfKaibun).reverse new StringBuilder(rSHarfKaibun) outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No" outputStr len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No" len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun) sSHarfKaibun.equals(sRHarfKaibun) sSHarfKaibun.equals(rRHarfKaibun) len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun) len >= 3 len 3 len <= 99 len 99 sSHarfKaibun.equals(rRHarfKaibun) sSHarfKaibun.equals sSHarfKaibun rRHarfKaibun sSHarfKaibun.equals(sRHarfKaibun) sSHarfKaibun.equals sSHarfKaibun sRHarfKaibun rSHarfKaibun.equals(rRHarfKaibun) rSHarfKaibun.equals rSHarfKaibun rRHarfKaibun "Yes" "No" System.out.println(outputStr) System.out.println System.out System System.out outputStr return; private static int getStdInNum() {
        String line1 = getStdInSingleLine();
        if (isNumber(line1)) {
            return Integer.parseInt(line1);
        }
        return 0;
    } getStdInNum {
        String line1 = getStdInSingleLine();
        if (isNumber(line1)) {
            return Integer.parseInt(line1);
        }
        return 0;
    } String line1 = getStdInSingleLine(); line1 getStdInSingleLine() getStdInSingleLine if (isNumber(line1)) {
            return Integer.parseInt(line1);
        } isNumber(line1) isNumber line1 {
            return Integer.parseInt(line1);
        } return Integer.parseInt(line1); Integer.parseInt(line1) Integer.parseInt Integer line1 return 0; 0 private static ArrayList<String> getStdInMultiLines() {
        int cnt = 0; 
        int max = 0;

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        }
        cin.close();
        return list;
    } getStdInMultiLines {
        int cnt = 0; 
        int max = 0;

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        }
        cin.close();
        return list;
    } int cnt = 0; cnt 0 int max = 0; max 0 Scanner cin = new Scanner(System.in); cin new Scanner(System.in) ArrayList<String> list = new ArrayList<String>(); list new ArrayList<String>() for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        } ; cin.hasNext() cin.hasNext cin {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        } {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        } list.add(cin.nextLine()) list.add list cin.nextLine() cin.nextLine cin if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            } cnt++ == 0 cnt++ cnt 0 {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            } max = Integer.parseInt((list.get(0)).split(" ")[0]) max Integer.parseInt((list.get(0)).split(" ")[0]) Integer.parseInt Integer (list.get(0)).split(" ")[0] (list.get(0)).split(" ") (list.get(0)).split (list.get(0)) list.get list 0 " " 0 if (cnt == max + 1) {
                break;
            } cnt == max + 1 cnt max + 1 max 1 {
                break;
            } break; cin.close() cin.close cin return list; list private static ArrayList<String> getStdInMultiLines(int inputLinesCnt) {
        int cnt = 0; 

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        }
        cin.close();
        return list;
    } getStdInMultiLines {
        int cnt = 0; 

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        }
        cin.close();
        return list;
    } int cnt = 0; cnt 0 Scanner cin = new Scanner(System.in); cin new Scanner(System.in) ArrayList<String> list = new ArrayList<String>(); list new ArrayList<String>() for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        } ; cin.hasNext() cin.hasNext cin {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        } {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        } list.add(cin.nextLine()) list.add list cin.nextLine() cin.nextLine cin if (++cnt == inputLinesCnt) {
                break;
            } ++cnt == inputLinesCnt ++cnt cnt inputLinesCnt {
                break;
            } break; cin.close() cin.close cin return list; list int inputLinesCnt inputLinesCnt private static String getStdInSingleLine() {
        Scanner cin = new Scanner(System.in);

        for (;cin.hasNext();) {
            cin.close();
            return cin.nextLine();
        }

        cin.close();
        return "";
    } getStdInSingleLine {
        Scanner cin = new Scanner(System.in);

        for (;cin.hasNext();) {
            cin.close();
            return cin.nextLine();
        }

        cin.close();
        return "";
    } Scanner cin = new Scanner(System.in); cin new Scanner(System.in) for (;cin.hasNext();) {
            cin.close();
            return cin.nextLine();
        } ; cin.hasNext() cin.hasNext cin {
            cin.close();
            return cin.nextLine();
        } {
            cin.close();
            return cin.nextLine();
        } cin.close() cin.close cin return cin.nextLine(); cin.nextLine() cin.nextLine cin cin.close() cin.close cin return ""; "" private static boolean isNumber(String val) {
        try {
            Integer.parseInt(val);
            return true;
        }
        catch (NumberFormatException nfex) {
            return false;
        }
    } isNumber {
        try {
            Integer.parseInt(val);
            return true;
        }
        catch (NumberFormatException nfex) {
            return false;
        }
    } try {
            Integer.parseInt(val);
            return true;
        }
        catch (NumberFormatException nfex) {
            return false;
        } catch (NumberFormatException nfex) {
            return false;
        } NumberFormatException nfex {
            return false;
        } return false; false {
            Integer.parseInt(val);
            return true;
        } Integer.parseInt(val) Integer.parseInt Integer val return true; true String val val public class Main {
    public static void main(String[] args){
        ABC159B();
    }
    private static void ABC159B() {
        // no comment, no error check
        final int INPUT_LINES_CNT = 1;

        ArrayList<String> inputLines = getStdInMultiLines(INPUT_LINES_CNT);

        if (inputLines.size() == 0) {
            System.out.println(0);
            return;
        }

        String outputStr;
        try {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        }
        catch (Exception ex) {
            outputStr = "No";
        }

        System.out.println(outputStr);
        return;
    }

private static int getStdInNum() {
        String line1 = getStdInSingleLine();
        if (isNumber(line1)) {
            return Integer.parseInt(line1);
        }
        return 0;
    }

    private static ArrayList<String> getStdInMultiLines() {
        int cnt = 0; 
        int max = 0;

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        }
        cin.close();
        return list;
    }
    private static ArrayList<String> getStdInMultiLines(int inputLinesCnt) {
        int cnt = 0; 

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        }
        cin.close();
        return list;
    }

    private static String getStdInSingleLine() {
        Scanner cin = new Scanner(System.in);

        for (;cin.hasNext();) {
            cin.close();
            return cin.nextLine();
        }

        cin.close();
        return "";
    }

    private static boolean isNumber(String val) {
        try {
            Integer.parseInt(val);
            return true;
        }
        catch (NumberFormatException nfex) {
            return false;
        }
    }

} public class Main {
    public static void main(String[] args){
        ABC159B();
    }
    private static void ABC159B() {
        // no comment, no error check
        final int INPUT_LINES_CNT = 1;

        ArrayList<String> inputLines = getStdInMultiLines(INPUT_LINES_CNT);

        if (inputLines.size() == 0) {
            System.out.println(0);
            return;
        }

        String outputStr;
        try {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        }
        catch (Exception ex) {
            outputStr = "No";
        }

        System.out.println(outputStr);
        return;
    }

private static int getStdInNum() {
        String line1 = getStdInSingleLine();
        if (isNumber(line1)) {
            return Integer.parseInt(line1);
        }
        return 0;
    }

    private static ArrayList<String> getStdInMultiLines() {
        int cnt = 0; 
        int max = 0;

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        }
        cin.close();
        return list;
    }
    private static ArrayList<String> getStdInMultiLines(int inputLinesCnt) {
        int cnt = 0; 

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        }
        cin.close();
        return list;
    }

    private static String getStdInSingleLine() {
        Scanner cin = new Scanner(System.in);

        for (;cin.hasNext();) {
            cin.close();
            return cin.nextLine();
        }

        cin.close();
        return "";
    }

    private static boolean isNumber(String val) {
        try {
            Integer.parseInt(val);
            return true;
        }
        catch (NumberFormatException nfex) {
            return false;
        }
    }

} Main
import java.util.*;

public class Main {
    public static void main(String[] args){
        ABC159B();
    }
    private static void ABC159B() {
        // no comment, no error check
        final int INPUT_LINES_CNT = 1;

        ArrayList<String> inputLines = getStdInMultiLines(INPUT_LINES_CNT);

        if (inputLines.size() == 0) {
            System.out.println(0);
            return;
        }

        String outputStr;
        try {
            List<String> inputLineList = Arrays.asList((inputLines.get(0)));
            String kaibun = inputLineList.get(0);
            int len = kaibun.length();
            String sSHarfKaibun = inputLineList.get(0).substring(0,len / 2);
            String sRHarfKaibun = new StringBuilder(sSHarfKaibun).reverse().toString();
            String rSHarfKaibun = inputLineList.get(0).substring(len / 2 + len % 2, len);
            String rRHarfKaibun = new StringBuilder(rSHarfKaibun).reverse().toString();

            outputStr = len >= 3 && len <= 99 && sSHarfKaibun.equals(rRHarfKaibun) 
                && sSHarfKaibun.equals(sRHarfKaibun) && rSHarfKaibun.equals(rRHarfKaibun)
                ? "Yes" : "No";
        }
        catch (Exception ex) {
            outputStr = "No";
        }

        System.out.println(outputStr);
        return;
    }

private static int getStdInNum() {
        String line1 = getStdInSingleLine();
        if (isNumber(line1)) {
            return Integer.parseInt(line1);
        }
        return 0;
    }

    private static ArrayList<String> getStdInMultiLines() {
        int cnt = 0; 
        int max = 0;

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (cnt++ == 0) {
                max = Integer.parseInt((list.get(0)).split(" ")[0]);
            }
            else if (cnt == max + 1) {
                break;
            }
        }
        cin.close();
        return list;
    }
    private static ArrayList<String> getStdInMultiLines(int inputLinesCnt) {
        int cnt = 0; 

        Scanner cin = new Scanner(System.in);
        ArrayList<String> list = new ArrayList<String>();
        for (;cin.hasNext();) {
            list.add(cin.nextLine());
            if (++cnt == inputLinesCnt) {
                break;
            }
        }
        cin.close();
        return list;
    }

    private static String getStdInSingleLine() {
        Scanner cin = new Scanner(System.in);

        for (;cin.hasNext();) {
            cin.close();
            return cin.nextLine();
        }

        cin.close();
        return "";
    }

    private static boolean isNumber(String val) {
        try {
            Integer.parseInt(val);
            return true;
        }
        catch (NumberFormatException nfex) {
            return false;
        }
    }

}
