#include <bits/stdc++.h>

using namespace std;

#define pb push_back
#define sc scanf
#define pf printf
#define ll long long
#define sz size()

int main()
{
    ll n,i,b,w,t;
    string s;
    while(cin>>s)
    {
        n= s.size();
        int cnt=0;
        for(i=0; i<n/2; i++)
        {
            if(s[i]!=s[n-1-i]) cnt++;
        }
        cout<<cnt<<endl;
    }
    return 0;
}
