import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		String S;
		Scanner sc = new Scanner(System.in);
		S = sc.next();
		int minIndex = 0;
		int maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = 0;
		maxIndex = (S.length() - 1) / 2 - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = (S.length() + 3) / 2 - 1;
		maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		System.out.println("Yes");
		sc.close();
	}

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

	public static void main(String[] args) {
		String S;
		Scanner sc = new Scanner(System.in);
		S = sc.next();
		int minIndex = 0;
		int maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = 0;
		maxIndex = (S.length() - 1) / 2 - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = (S.length() + 3) / 2 - 1;
		maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		System.out.println("Yes");
		sc.close();
	}

} Main public static void main(String[] args) {
		String S;
		Scanner sc = new Scanner(System.in);
		S = sc.next();
		int minIndex = 0;
		int maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = 0;
		maxIndex = (S.length() - 1) / 2 - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = (S.length() + 3) / 2 - 1;
		maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		System.out.println("Yes");
		sc.close();
	} main {
		String S;
		Scanner sc = new Scanner(System.in);
		S = sc.next();
		int minIndex = 0;
		int maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = 0;
		maxIndex = (S.length() - 1) / 2 - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = (S.length() + 3) / 2 - 1;
		maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		System.out.println("Yes");
		sc.close();
	} String S; S Scanner sc = new Scanner(System.in); sc new Scanner(System.in) S = sc.next() S sc.next() sc.next sc int minIndex = 0; minIndex 0 int maxIndex = S.length() - 1; maxIndex S.length() - 1 S.length() S.length S 1 while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		} minIndex < maxIndex minIndex maxIndex {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		} if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			} S.charAt(minIndex++) != S.charAt(maxIndex--) S.charAt(minIndex++) S.charAt S minIndex++ minIndex S.charAt(maxIndex--) S.charAt S maxIndex-- maxIndex {
				System.out.println("No");
				System.exit(0);
			} System.out.println("No") System.out.println System.out System System.out "No" System.exit(0) System.exit System 0 minIndex = 0 minIndex 0 maxIndex = (S.length() - 1) / 2 - 1 maxIndex (S.length() - 1) / 2 - 1 (S.length() - 1) / 2 (S.length() - 1) S.length() S.length S 1 2 1 while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		} minIndex < maxIndex minIndex maxIndex {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		} if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			} S.charAt(minIndex++) != S.charAt(maxIndex--) S.charAt(minIndex++) S.charAt S minIndex++ minIndex S.charAt(maxIndex--) S.charAt S maxIndex-- maxIndex {
				System.out.println("No");
				System.exit(0);
			} System.out.println("No") System.out.println System.out System System.out "No" System.exit(0) System.exit System 0 minIndex = (S.length() + 3) / 2 - 1 minIndex (S.length() + 3) / 2 - 1 (S.length() + 3) / 2 (S.length() + 3) S.length() S.length S 3 2 1 maxIndex = S.length() - 1 maxIndex S.length() - 1 S.length() S.length S 1 while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		} minIndex < maxIndex minIndex maxIndex {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		} if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			} S.charAt(minIndex++) != S.charAt(maxIndex--) S.charAt(minIndex++) S.charAt S minIndex++ minIndex S.charAt(maxIndex--) S.charAt S maxIndex-- maxIndex {
				System.out.println("No");
				System.exit(0);
			} System.out.println("No") System.out.println System.out System System.out "No" System.exit(0) System.exit System 0 System.out.println("Yes") System.out.println System.out System System.out "Yes" sc.close() sc.close sc String[] args args public class Main {

	public static void main(String[] args) {
		String S;
		Scanner sc = new Scanner(System.in);
		S = sc.next();
		int minIndex = 0;
		int maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = 0;
		maxIndex = (S.length() - 1) / 2 - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = (S.length() + 3) / 2 - 1;
		maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		System.out.println("Yes");
		sc.close();
	}

} public class Main {

	public static void main(String[] args) {
		String S;
		Scanner sc = new Scanner(System.in);
		S = sc.next();
		int minIndex = 0;
		int maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = 0;
		maxIndex = (S.length() - 1) / 2 - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = (S.length() + 3) / 2 - 1;
		maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		System.out.println("Yes");
		sc.close();
	}

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		String S;
		Scanner sc = new Scanner(System.in);
		S = sc.next();
		int minIndex = 0;
		int maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = 0;
		maxIndex = (S.length() - 1) / 2 - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		minIndex = (S.length() + 3) / 2 - 1;
		maxIndex = S.length() - 1;
		while (minIndex < maxIndex) {
			if (S.charAt(minIndex++) != S.charAt(maxIndex--)) {
				System.out.println("No");
				System.exit(0);
			}
		}
		System.out.println("Yes");
		sc.close();
	}

}