fun main(args: Array<String>) {
    val s = readLine()!!
    val s1 = s.substring(0, (s.length-1)/2)
    val s2 = s.substring((s.length+1)/2, s.length)
    println(if (solve(s) && solve(s1) && solve(s2)) "Yes" else "No")
}

fun solve(s: String): Boolean {
    return s == s.reversed()
}
