import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		int n = str.length();
		String s1 = str.substring(0, (n - 1) / 2);
		String s2 = str.substring((n + 3) / 2 - 1, n);
		//System.out.println(s1);
		//System.out.println(s2);
		char[] a = s1.toCharArray();
		char[] b = s2.toCharArray();
		int a1 = 0;
		int b1 = 0;//回文になっていなければ①増やす→0ならば回文
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		}
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		}
		char[] c = str.toCharArray();
		int c1 = 0;
		for (int i = 0; i < (n - 1) / 2; i++) {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		}
		if (a1 == 0 && b1 == 0 && c1 == 0) {
			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 sc = new Scanner(System.in);
		String str = sc.next();
		int n = str.length();
		String s1 = str.substring(0, (n - 1) / 2);
		String s2 = str.substring((n + 3) / 2 - 1, n);
		//System.out.println(s1);
		//System.out.println(s2);
		char[] a = s1.toCharArray();
		char[] b = s2.toCharArray();
		int a1 = 0;
		int b1 = 0;//回文になっていなければ①増やす→0ならば回文
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		}
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		}
		char[] c = str.toCharArray();
		int c1 = 0;
		for (int i = 0; i < (n - 1) / 2; i++) {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		}
		if (a1 == 0 && b1 == 0 && c1 == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		int n = str.length();
		String s1 = str.substring(0, (n - 1) / 2);
		String s2 = str.substring((n + 3) / 2 - 1, n);
		//System.out.println(s1);
		//System.out.println(s2);
		char[] a = s1.toCharArray();
		char[] b = s2.toCharArray();
		int a1 = 0;
		int b1 = 0;//回文になっていなければ①増やす→0ならば回文
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		}
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		}
		char[] c = str.toCharArray();
		int c1 = 0;
		for (int i = 0; i < (n - 1) / 2; i++) {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		}
		if (a1 == 0 && b1 == 0 && c1 == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	} main {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		int n = str.length();
		String s1 = str.substring(0, (n - 1) / 2);
		String s2 = str.substring((n + 3) / 2 - 1, n);
		//System.out.println(s1);
		//System.out.println(s2);
		char[] a = s1.toCharArray();
		char[] b = s2.toCharArray();
		int a1 = 0;
		int b1 = 0;//回文になっていなければ①増やす→0ならば回文
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		}
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		}
		char[] c = str.toCharArray();
		int c1 = 0;
		for (int i = 0; i < (n - 1) / 2; i++) {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		}
		if (a1 == 0 && b1 == 0 && c1 == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String str = sc.next(); str sc.next() sc.next sc int n = str.length(); n str.length() str.length str String s1 = str.substring(0, (n - 1) / 2); s1 str.substring(0, (n - 1) / 2) str.substring str 0 (n - 1) / 2 (n - 1) n 1 2 String s2 = str.substring((n + 3) / 2 - 1, n); s2 str.substring((n + 3) / 2 - 1, n) str.substring str (n + 3) / 2 - 1 (n + 3) / 2 (n + 3) n 3 2 1 n char[] a = s1.toCharArray(); a s1.toCharArray() s1.toCharArray s1 char[] b = s2.toCharArray(); b s2.toCharArray() s2.toCharArray s2 int a1 = 0; a1 0 int b1 = 0; b1 0 for (int i = 0; i < (n - 1) / 4; i++) {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		} int i = 0; int i = 0; i 0 i < (n - 1) / 4 i (n - 1) / 4 (n - 1) n 1 4 i++ i++ i {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		} {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		} if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			} a[i] != a[(n - 1) / 2 - 1 - i] a[i] a i a[(n - 1) / 2 - 1 - i] a (n - 1) / 2 - 1 - i (n - 1) / 2 - 1 - i (n - 1) / 2 (n - 1) n 1 2 1 i {
				a1++;
			} a1++ a1 for (int i = 0; i < (n - 1) / 4; i++) {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		} int i = 0; int i = 0; i 0 i < (n - 1) / 4 i (n - 1) / 4 (n - 1) n 1 4 i++ i++ i {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		} {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		} if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			} b[i] != b[(n - 1) / 2 - 1 - i] b[i] b i b[(n - 1) / 2 - 1 - i] b (n - 1) / 2 - 1 - i (n - 1) / 2 - 1 - i (n - 1) / 2 (n - 1) n 1 2 1 i {
				b1++;
			} b1++ b1 char[] c = str.toCharArray(); c str.toCharArray() str.toCharArray str int c1 = 0; c1 0 for (int i = 0; i < (n - 1) / 2; i++) {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		} 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 (c[i] != c[n - 1 - i]) {
				c1++;
			}
		} {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		} if (c[i] != c[n - 1 - i]) {
				c1++;
			} c[i] != c[n - 1 - i] c[i] c i c[n - 1 - i] c n - 1 - i n - 1 - i n 1 i {
				c1++;
			} c1++ c1 if (a1 == 0 && b1 == 0 && c1 == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		} a1 == 0 && b1 == 0 && c1 == 0 a1 == 0 && b1 == 0 && c1 == 0 a1 == 0 a1 0 b1 == 0 b1 0 c1 == 0 c1 0 {
			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 sc = new Scanner(System.in);
		String str = sc.next();
		int n = str.length();
		String s1 = str.substring(0, (n - 1) / 2);
		String s2 = str.substring((n + 3) / 2 - 1, n);
		//System.out.println(s1);
		//System.out.println(s2);
		char[] a = s1.toCharArray();
		char[] b = s2.toCharArray();
		int a1 = 0;
		int b1 = 0;//回文になっていなければ①増やす→0ならば回文
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		}
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		}
		char[] c = str.toCharArray();
		int c1 = 0;
		for (int i = 0; i < (n - 1) / 2; i++) {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		}
		if (a1 == 0 && b1 == 0 && c1 == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		int n = str.length();
		String s1 = str.substring(0, (n - 1) / 2);
		String s2 = str.substring((n + 3) / 2 - 1, n);
		//System.out.println(s1);
		//System.out.println(s2);
		char[] a = s1.toCharArray();
		char[] b = s2.toCharArray();
		int a1 = 0;
		int b1 = 0;//回文になっていなければ①増やす→0ならば回文
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		}
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		}
		char[] c = str.toCharArray();
		int c1 = 0;
		for (int i = 0; i < (n - 1) / 2; i++) {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		}
		if (a1 == 0 && b1 == 0 && c1 == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		int n = str.length();
		String s1 = str.substring(0, (n - 1) / 2);
		String s2 = str.substring((n + 3) / 2 - 1, n);
		//System.out.println(s1);
		//System.out.println(s2);
		char[] a = s1.toCharArray();
		char[] b = s2.toCharArray();
		int a1 = 0;
		int b1 = 0;//回文になっていなければ①増やす→0ならば回文
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (a[i] != a[(n - 1) / 2 - 1 - i]) {
				a1++;
			}
		}
		for (int i = 0; i < (n - 1) / 4; i++) {
			if (b[i] != b[(n - 1) / 2 - 1 - i]) {
				b1++;
			}
		}
		char[] c = str.toCharArray();
		int c1 = 0;
		for (int i = 0; i < (n - 1) / 2; i++) {

			if (c[i] != c[n - 1 - i]) {
				c1++;
			}
		}
		if (a1 == 0 && b1 == 0 && c1 == 0) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

}
