#include<iostream>
#include<string>
using namespace std;
int main(){
	string a;
	while(1){
		cin >> a;
		if(a.length() < 20)
			break;
	}
	for(int i=a.length()-1; i>-1; i--){
		cout << a[i];
		}
	return 0;
}