open System 

type Explicit =          
    static member inline ($) (_:int32, _:Explicit) = int
    static member inline ($) (_:int64, _:Explicit) = int64

let inline convert (value:'a): 'b = 
    (Unchecked.defaultof<'b> $ Unchecked.defaultof<Explicit>) value

let inline fromInt (x: int): 'a = convert x

module NumericLiteralG =
    let inline FromZero(): ^a = LanguagePrimitives.GenericZero
    let inline FromOne(): ^a = LanguagePrimitives.GenericOne
    let inline FromInt32 n = fromInt n

let R() = Console.ReadLine()

let f (s: string): bool =
    let isP s = s = new string(s.ToCharArray() |> Array.rev)
    let f = s.Substring(0, s.Length - 1 / 2)
    let b = s.Substring((s.Length + 3) / 2 - 1)
    let f1 = isP s 
    let f2 = isP f 
    let f3 = isP b 
    f1 && f2 && f3 

let S = R() 

f S 
|> function 
| true -> "Yes"
| _ -> "No"
|> printfn "%s"