#include<iostream>
#include<string>

using namespace std;

int main(){
    int i,j,k;
    string s;
    cin >> s;
    k = s.length();
    for(i=k-1;i>=0;i--){
        cout<<s[i];
    }
    cout << endl;
    return 0;
}