import java.util.Scanner;

public class Main {
	

	public static boolean check(String k,int i,int j) {
		
		while(i<j) {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		}
		return true;
	}
	public static void main(String[] args) {

		Scanner s = new Scanner(System.in);
		String s1 = s.next();
		int n = s1.length();
		
		if(check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1)) {
			System.out.println("Yes");
		}
		else {
			System.out.println("No");
		}
		
	}
} import java.util.Scanner; Scanner java.util public class Main {
	

	public static boolean check(String k,int i,int j) {
		
		while(i<j) {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		}
		return true;
	}
	public static void main(String[] args) {

		Scanner s = new Scanner(System.in);
		String s1 = s.next();
		int n = s1.length();
		
		if(check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1)) {
			System.out.println("Yes");
		}
		else {
			System.out.println("No");
		}
		
	}
} Main public static boolean check(String k,int i,int j) {
		
		while(i<j) {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		}
		return true;
	} check {
		
		while(i<j) {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		}
		return true;
	} while(i<j) {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		} i<j i j {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		} if(k.charAt(i)!=k.charAt(j))
				return false; k.charAt(i)!=k.charAt(j) k.charAt(i) k.charAt k i k.charAt(j) k.charAt k j return false; false i++ i j-- j return true; true String k k int i i int j j public static void main(String[] args) {

		Scanner s = new Scanner(System.in);
		String s1 = s.next();
		int n = s1.length();
		
		if(check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1)) {
			System.out.println("Yes");
		}
		else {
			System.out.println("No");
		}
		
	} main {

		Scanner s = new Scanner(System.in);
		String s1 = s.next();
		int n = s1.length();
		
		if(check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1)) {
			System.out.println("Yes");
		}
		else {
			System.out.println("No");
		}
		
	} Scanner s = new Scanner(System.in); s new Scanner(System.in) String s1 = s.next(); s1 s.next() s.next s int n = s1.length(); n s1.length() s1.length s1 if(check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1)) {
			System.out.println("Yes");
		}
		else {
			System.out.println("No");
		} check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1) check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1) check(s1,0,n-1) check s1 0 n-1 n 1 check(s1,0,(n-1)/2-1) check s1 0 (n-1)/2-1 (n-1)/2 (n-1) n 1 2 1 check(s1,(n+1)/2,n-1) check s1 (n+1)/2 (n+1) n 1 2 n-1 n 1 {
			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" String[] args args public class Main {
	

	public static boolean check(String k,int i,int j) {
		
		while(i<j) {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		}
		return true;
	}
	public static void main(String[] args) {

		Scanner s = new Scanner(System.in);
		String s1 = s.next();
		int n = s1.length();
		
		if(check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1)) {
			System.out.println("Yes");
		}
		else {
			System.out.println("No");
		}
		
	}
} public class Main {
	

	public static boolean check(String k,int i,int j) {
		
		while(i<j) {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		}
		return true;
	}
	public static void main(String[] args) {

		Scanner s = new Scanner(System.in);
		String s1 = s.next();
		int n = s1.length();
		
		if(check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1)) {
			System.out.println("Yes");
		}
		else {
			System.out.println("No");
		}
		
	}
} Main
import java.util.Scanner;

public class Main {
	

	public static boolean check(String k,int i,int j) {
		
		while(i<j) {
			if(k.charAt(i)!=k.charAt(j))
				return false;
			i++;
			j--;
			
		}
		return true;
	}
	public static void main(String[] args) {

		Scanner s = new Scanner(System.in);
		String s1 = s.next();
		int n = s1.length();
		
		if(check(s1,0,n-1) && check(s1,0,(n-1)/2-1) && check(s1,(n+1)/2,n-1)) {
			System.out.println("Yes");
		}
		else {
			System.out.println("No");
		}
		
	}
}