import java.util.*;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    String S = sc.next();
    char[] charS = S.toCharArray();
    int N = charS.length;
    boolean isStrong = true;
    for(int i=0; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      }
    }
    for(int i=0; i<(N-1)/2; i++){
      if(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      }
    }
    for(int i=(N+3)/2-1; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
      }
    }
    

    if(isStrong){
      System.out.println("Yes");
    }else{
      System.out.println("No");
    }
  }
} import java.util.*; util.* java class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    String S = sc.next();
    char[] charS = S.toCharArray();
    int N = charS.length;
    boolean isStrong = true;
    for(int i=0; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      }
    }
    for(int i=0; i<(N-1)/2; i++){
      if(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      }
    }
    for(int i=(N+3)/2-1; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
      }
    }
    

    if(isStrong){
      System.out.println("Yes");
    }else{
      System.out.println("No");
    }
  }
} Main public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    String S = sc.next();
    char[] charS = S.toCharArray();
    int N = charS.length;
    boolean isStrong = true;
    for(int i=0; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      }
    }
    for(int i=0; i<(N-1)/2; i++){
      if(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      }
    }
    for(int i=(N+3)/2-1; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
      }
    }
    

    if(isStrong){
      System.out.println("Yes");
    }else{
      System.out.println("No");
    }
  } main {
    Scanner sc = new Scanner(System.in);
    String S = sc.next();
    char[] charS = S.toCharArray();
    int N = charS.length;
    boolean isStrong = true;
    for(int i=0; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      }
    }
    for(int i=0; i<(N-1)/2; i++){
      if(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      }
    }
    for(int i=(N+3)/2-1; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
      }
    }
    

    if(isStrong){
      System.out.println("Yes");
    }else{
      System.out.println("No");
    }
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String S = sc.next(); S sc.next() sc.next sc char[] charS = S.toCharArray(); charS S.toCharArray() S.toCharArray S int N = charS.length; N charS.length charS charS.length boolean isStrong = true; isStrong true for(int i=0; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      }
    } int i=0; int i=0; i 0 i<N i N i++ i++ i {
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      }
    } {
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      }
    } if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      } charS[i] != charS[N-1-i] charS[i] charS i charS[N-1-i] charS N-1-i N-1-i N 1 i {
        isStrong=false;
        break;
      } isStrong=false isStrong false break; for(int i=0; i<(N-1)/2; i++){
      if(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      }
    } 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(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      }
    } {
      if(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      }
    } if(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      } charS[i] != charS[(N-1)/2-1-i] charS[i] charS i charS[(N-1)/2-1-i] charS (N-1)/2-1-i (N-1)/2-1-i (N-1)/2 (N-1) N 1 2 1 i {
        isStrong=false;
      } isStrong=false isStrong false for(int i=(N+3)/2-1; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
      }
    } int i=(N+3)/2-1; int i=(N+3)/2-1; i (N+3)/2-1 (N+3)/2 (N+3) N 3 2 1 i<N i N i++ i++ i {
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
      }
    } {
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
      }
    } if(charS[i] != charS[N-1-i]){
        isStrong=false;
      } charS[i] != charS[N-1-i] charS[i] charS i charS[N-1-i] charS N-1-i N-1-i N 1 i {
        isStrong=false;
      } isStrong=false isStrong false if(isStrong){
      System.out.println("Yes");
    }else{
      System.out.println("No");
    } isStrong {
      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
import java.util.*;
class Main{
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    String S = sc.next();
    char[] charS = S.toCharArray();
    int N = charS.length;
    boolean isStrong = true;
    for(int i=0; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
        break;
      }
    }
    for(int i=0; i<(N-1)/2; i++){
      if(charS[i] != charS[(N-1)/2-1-i]){
        isStrong=false;
      }
    }
    for(int i=(N+3)/2-1; i<N; i++){
      if(charS[i] != charS[N-1-i]){
        isStrong=false;
      }
    }
    

    if(isStrong){
      System.out.println("Yes");
    }else{
      System.out.println("No");
    }
  }
}
