import java.util.Scanner;
public class Main {
	public static void main(String[] args){
		Scanner as = new Scanner(System.in);
		String a = as.next();
		String l = "NO";
		int n = a.length();
		boolean t = true;
		int alice = 0;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		}
		//System.out.println(alice);
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<n/2;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		if(alice == 3){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args){
		Scanner as = new Scanner(System.in);
		String a = as.next();
		String l = "NO";
		int n = a.length();
		boolean t = true;
		int alice = 0;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		}
		//System.out.println(alice);
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<n/2;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		if(alice == 3){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}
} Main public static void main(String[] args){
		Scanner as = new Scanner(System.in);
		String a = as.next();
		String l = "NO";
		int n = a.length();
		boolean t = true;
		int alice = 0;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		}
		//System.out.println(alice);
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<n/2;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		if(alice == 3){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	} main {
		Scanner as = new Scanner(System.in);
		String a = as.next();
		String l = "NO";
		int n = a.length();
		boolean t = true;
		int alice = 0;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		}
		//System.out.println(alice);
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<n/2;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		if(alice == 3){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	} Scanner as = new Scanner(System.in); as new Scanner(System.in) String a = as.next(); a as.next() as.next as String l = "NO"; l "NO" int n = a.length(); n a.length() a.length a boolean t = true; t true int alice = 0; alice 0 for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		} int i=0; int i=0; i 0 i<(n-1)/4 i (n-1)/4 (n-1) n 1 4 i++ i++ i {
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		} {
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		} if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			} String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1))) String.valueOf(a.charAt(i)).equals String.valueOf(a.charAt(i)) String.valueOf String a.charAt(i) a.charAt a i String.valueOf(a.charAt((n-1)/2-i-1)) String.valueOf String a.charAt((n-1)/2-i-1) a.charAt a (n-1)/2-i-1 (n-1)/2-i-1 (n-1)/2 (n-1) n 1 2 i 1 {
				t = true;
			} t = true t true {
				//System.out.println(i);
				t = false;
				break;
			} t = false t false break; if(t){
			alice++;
		} t {
			alice++;
		} alice++ alice t = true t true for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		} int i=0; int i=0; i 0 i<(n-1)/4 i (n-1)/4 (n-1) n 1 4 i++ i++ i {
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		} {
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		} if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			} String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1))) String.valueOf(a.charAt((n+3)/2+i-1)).equals String.valueOf(a.charAt((n+3)/2+i-1)) String.valueOf String a.charAt((n+3)/2+i-1) a.charAt a (n+3)/2+i-1 (n+3)/2+i (n+3)/2 (n+3) n 3 2 i 1 String.valueOf(a.charAt(n-i-1)) String.valueOf String a.charAt(n-i-1) a.charAt a n-i-1 n-i-1 n i 1 {
				t = true;
			} t = true t true {
				t = false;
				break;
			} t = false t false break; if(t){
			alice++;
		} t {
			alice++;
		} alice++ alice t = true t true for(int i=0;i<n/2;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		} int i=0; int i=0; i 0 i<n/2 i n/2 n 2 i++ i++ i {
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		} {
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		} if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			} String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1))) String.valueOf(a.charAt(i)).equals String.valueOf(a.charAt(i)) String.valueOf String a.charAt(i) a.charAt a i String.valueOf(a.charAt(n-i-1)) String.valueOf String a.charAt(n-i-1) a.charAt a n-i-1 n-i-1 n i 1 {
				t = true;
			} t = true t true {
				t = false;
				break;
			} t = false t false break; if(t){
			alice++;
		} t {
			alice++;
		} alice++ alice if(alice == 3){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		} alice == 3 alice 3 {
			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 void main(String[] args){
		Scanner as = new Scanner(System.in);
		String a = as.next();
		String l = "NO";
		int n = a.length();
		boolean t = true;
		int alice = 0;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		}
		//System.out.println(alice);
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<n/2;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		if(alice == 3){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}
} public class Main {
	public static void main(String[] args){
		Scanner as = new Scanner(System.in);
		String a = as.next();
		String l = "NO";
		int n = a.length();
		boolean t = true;
		int alice = 0;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		}
		//System.out.println(alice);
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<n/2;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		if(alice == 3){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}
} Main
import java.util.Scanner;
public class Main {
	public static void main(String[] args){
		Scanner as = new Scanner(System.in);
		String a = as.next();
		String l = "NO";
		int n = a.length();
		boolean t = true;
		int alice = 0;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt(i));
			//System.out.println(a.charAt((n-1)/2-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt((n-1)/2-i-1)))){
				t = true;
			}else{
				//System.out.println(i);
				t = false;
				break;
			}
		}
		//System.out.println(alice);
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<(n-1)/4;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt((n+3)/2+i-1)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		t = true;
		for(int i=0;i<n/2;i++){
			//System.out.println(a.charAt((n+3)/2+i-1));
			//System.out.println(a.charAt(n-i-1));
			if(String.valueOf(a.charAt(i)).equals(String.valueOf(a.charAt(n-i-1)))){
				t = true;
			}else{
				t = false;
				break;
			}
		}
		if(t){
			alice++;
		}
		//System.out.println(alice);
		if(alice == 3){
			System.out.println("Yes");
		}else{
			System.out.println("No");
		}
	}
}