#include <bits/stdc++.h>
#include <iostream>
#include <string>
#include <stdio.h>
#include <math.h>
#define rep(i,n) for (int i = 0; i < (n); ++i)
using ll = long long;
typedef long double lb;
using namespace std;
int main(){
  string S;
  cin >> S;
  int SI = S.size();
  for(int i = SI - 1; i >= 0; i--){
    cout << S[i];
  }
  cout << endl;
  return 0;
}
