s=gets.chomp
r=s.clone.reverse
cnt=0

if s.size%2==0
    s=s[0..(s.size/2)-1]
    r=r[0..(r.size/2)-1]
else
    s=s[0..((s.size-1)/2)-1]
    r=r[0..((r.size-1)/2)-1]
end

(0..s.size-1).each do |x|
    if s[x] != r[x]
        cnt +=1
    end
end
p cnt