main = do
  s <- getLine
  let n = length s
  let s_1 = take (ceiling ((fromIntegral n - 1) / 2)) s
  let s_2 = drop (ceiling ((fromIntegral n + 3) / 2) - 1) s
  if ck s s_1 s_2 == True
    then putStrLn "Yes"
    else putStrLn "No"

ck :: String -> String -> String -> Bool
ck s1 s2 s3 = and [s1 == reverse s1, s2 == reverse s2, s3 == reverse s3]