Problem:
Score : 200 points

Problem Statement

A string S of an odd length is said to be a strong palindrome if and only if all of the following conditions are satisfied:

S is a palindrome.

Let N be the length of S. The string formed by the 1-st through ((N-1)/2)-th characters of S is a palindrome.

The string consisting of the (N+3)/2-st through N-th characters of S is a palindrome.

Determine whether S is a strong palindrome.

Constraints

S consists of lowercase English letters.

The length of S is an odd number between 3 and 99 (inclusive).

Input

Input is given from Standard Input in the following format:

S

Output

If S is a strong palindrome, print Yes;
otherwise, print No.

Sample Input 1

akasaka

Sample Output 1

Yes

S is akasaka.

The string formed by the 1-st through the 3-rd characters is aka.

The string formed by the 5-th through the 7-th characters is aka.
All of these are palindromes, so S is a strong palindrome.

Sample Input 2

level

Sample Output 2

No

Sample Input 3

atcoder

Sample Output 3

No

Solution in C (Clang 3.8.0) (judge verdict: Accepted)

#include <stdio.h>

int main (void){
    int a, b, c, i, i2, i3;
    char str[100];
    char cp[50];
    i3 = 0;

    scanf("%s", str);
    for ( i = 0; str[i] != '\0'; i++ ){		//入力された文字数を探索 ~7
//        printf("%d", i);
    }
    for ( i2 = 0; i2 <= (i-1)/2-1; i2++ ){	//前半の文字列をコピー ~2
        cp[i2] = str[i2];
    }
//  	printf("%c %c\n", str[0], cp[0] );
    for ( i2 = (i+3)/2-1; i2 < i; i2++, i3++ ){	//コピー文字列と後半文字列を比較 4~
        if ( str[i2] != cp[i3] ){
            printf("No");
            return 0;
        }
    }
    printf("Yes");
    return 0;
}