function Main(input) {
    input = input.split("");
    var head = [];
    var tail = [];
    var ans = 0;
    if(input.length%2 == 1){
        ans
    }
    
    for(var i = 0; i < input.length;i++){
        if(i < input.length/2){
            head.push(input[i]);
        }else{
            tail.push(input[i]);
        }
    }
    tail.reverse();
    
    for(var i = 0; i < head.length;i++){
        if(head[i] != tail[i]){
            ans++;
        }
    }
    
    if((head.length != tail.length) && (ans != 0)){
        ans--;
    }
console.log(ans);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));