fun main(args: Array<String>) {
    val s = readLine()!!.split(" ")[0]
    val sArray = s.toCharArray()
    val length = s.length
    var count = 0
    for (i in 0 until length / 2) {
        if (sArray[i] != sArray[length - i - 1]) count++
    }
    println(count)
}