#include <iostream>
using namespace std;

int main(){
	char str[21];
	char temp[21];
	int i = 0;

	memset(str, 0, sizeof(str));
	memset(temp, 0, sizeof(temp));

	while(cin >> str){
		int n = strlen(str);
		for(; n!=0; ){
			temp[i++] = str[--n];
		}
		cout << temp << endl;
	}
	return 0;
}