program speedrun
    implicit none
    character(100)::S
    integer::ANS=0,L
    integer::i
    read*,S
    L=len_trim(S)
    do i=1,L/2
        if(S(i:i)/=S(L-i+1:L-i+1))ANS=ANS+1
    end do
    print"(i0)",ANS
end program speedrun