def is_p(s):

    return s == s[::-1]

s = eval(input())

n = len(s)

print(('Yes' if is_p(s) and is_p(s[:(n - 1)//2]) and is_p(s[(n + 3)//2 - 1:]) else 'No'))
def is_p(s):

    return s == s[::-1]

s = eval(input())

n = len(s)

l = (n - 1)//2

r = l + 1

print(('Yes' if is_p(s) and is_p(s[:l]) and is_p(s[r:]) else 'No'))
def is_p(s):
    return s == s[::-1]


s = eval(input())
n = len(s)
print(
    (
        "Yes"
        if is_p(s) and is_p(s[: (n - 1) // 2]) and is_p(s[(n + 3) // 2 - 1 :])
        else "No"
    )
)

def is_p(s):
    return s == s[::-1]


s = eval(input())
n = len(s)
l = (n - 1) // 2
r = l + 1
print(("Yes" if is_p(s) and is_p(s[:l]) and is_p(s[r:]) else "No"))

-print( -    ( -        "Yes" -        if is_p(s) and is_p(s[: (n - 1) // 2]) and is_p(s[(n + 3) // 2 - 1 :]) -        else "No" -    ) -) +l = (n - 1) // 2 +r = l + 1 +print(("Yes" if is_p(s) and is_p(s[:l]) and is_p(s[r:]) else "No"))