#include <iostream>
#include <string>
#include <algorithm>
#define REP(i,n) for(int i=0;i<n;i++)
using namespace std;

int main() {
    string s;
    cin >> s;
    reverse(s.begin(),s.end());
    cout << s << '\n';    
}