#include using namespace std; int main(){ string s,rs; int ans=0; cin >> s; rs=s;reverse(rs.begin(),rs.end()); for(int i=0;i