#include<iostream>
#include<string>
#include<algorithm>
using namespace std;

int main(){

  string s;

  cin >> s;

  reverse(s.begin(), s.end());

  //abcd
  //int len = s.length();
  // len = 4

  //for(int i = len; i >= 0; i--){
  //cout << s[i];
    //}

  cout << s << endl;

}