local A = tostring(io.read())

local counter = 0
for i=1 , #A/2 do
    if string.sub(A, i, i) ~= string.sub(string.reverse(A), i, i) then
        counter = counter + 1
    end
end
print(string.format("%d", counter))