fun main (args:Array<String>){
    var str = readLine()!!
    val strLen = str.length
    var strback = ""
    var count = 0
    //偶数の場合
    if(strLen % 2 == 0) strback += str.takeLast(strLen/ 2)
    // 奇数の場合
    else strback += str.takeLast((strLen - 1) / 2)

    strback = strback.reversed()
    for(i in 0..strback.length-1){
        if(str[i] != strback[i]) count++
    }
    print(count)
}