import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int N = S.length();
		sc.close();
		String a = "Yes";
		for(int i=0; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}
		for(int i=0; i<(N-1)/2; i++) {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		}
		for(int i=(N+3)/2; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}

		System.out.println(a);
	}

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

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int N = S.length();
		sc.close();
		String a = "Yes";
		for(int i=0; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}
		for(int i=0; i<(N-1)/2; i++) {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		}
		for(int i=(N+3)/2; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}

		System.out.println(a);
	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int N = S.length();
		sc.close();
		String a = "Yes";
		for(int i=0; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}
		for(int i=0; i<(N-1)/2; i++) {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		}
		for(int i=(N+3)/2; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}

		System.out.println(a);
	} main {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int N = S.length();
		sc.close();
		String a = "Yes";
		for(int i=0; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}
		for(int i=0; i<(N-1)/2; i++) {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		}
		for(int i=(N+3)/2; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}

		System.out.println(a);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String S = sc.next(); S sc.next() sc.next sc int N = S.length(); N S.length() S.length S sc.close() sc.close sc String a = "Yes"; a "Yes" for(int i=0; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		} {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		} if(S.charAt(i) != S.charAt(N-i-1))
				a = "No"; S.charAt(i) != S.charAt(N-i-1) S.charAt(i) S.charAt S i S.charAt(N-i-1) S.charAt S N-i-1 N-i-1 N i 1 a = "No" a "No" for(int i=0; i<(N-1)/2; i++) {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		} int i=0; int i=0; i 0 i<(N-1)/2 i (N-1)/2 (N-1) N 1 2 i++ i++ i {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		} {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		} if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No"; S.charAt(i) != S.charAt((N-1)/2-i-1) S.charAt(i) S.charAt S i S.charAt((N-1)/2-i-1) S.charAt S (N-1)/2-i-1 (N-1)/2-i-1 (N-1)/2 (N-1) N 1 2 i 1 a = "No" a "No" for(int i=(N+3)/2; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		} int i=(N+3)/2; int i=(N+3)/2; i (N+3)/2 (N+3) N 3 2 i<N i N i++ i++ i {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		} {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		} if(S.charAt(i) != S.charAt(N-i-1))
				a = "No"; S.charAt(i) != S.charAt(N-i-1) S.charAt(i) S.charAt S i S.charAt(N-i-1) S.charAt S N-i-1 N-i-1 N i 1 a = "No" a "No" System.out.println(a) System.out.println System.out System System.out a String[] args args public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int N = S.length();
		sc.close();
		String a = "Yes";
		for(int i=0; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}
		for(int i=0; i<(N-1)/2; i++) {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		}
		for(int i=(N+3)/2; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}

		System.out.println(a);
	}

} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int N = S.length();
		sc.close();
		String a = "Yes";
		for(int i=0; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}
		for(int i=0; i<(N-1)/2; i++) {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		}
		for(int i=(N+3)/2; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}

		System.out.println(a);
	}

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String S = sc.next();
		int N = S.length();
		sc.close();
		String a = "Yes";
		for(int i=0; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}
		for(int i=0; i<(N-1)/2; i++) {
			if(S.charAt(i) != S.charAt((N-1)/2-i-1))
				a = "No";
		}
		for(int i=(N+3)/2; i<N; i++) {
			if(S.charAt(i) != S.charAt(N-i-1))
				a = "No";
		}

		System.out.println(a);
	}

}