inp = require('fs').readFileSync('/dev/stdin', 'utf8').trim().split('\n')
s = inp.shift().split('')
c = 0
for(i=0;i<s.length/2;i++) {
    if (s[i] !== s[s.length - i - 1]) {
        c++
    }
}
console.log(c)