#include <iostream>
#include <sstream>
#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <cstring>
#include <string>
#include <vector>
#include <stack>
#include <queue>
#include <set>
#include <map>
#include <algorithm>
#include <functional>

using namespace std;

int gcd( int, int );

int main()
{
	char str[21];

	scanf("%s", str );
	for ( int i = strlen( str ) - 1; 0 <= i; i-- )
	{
		putchar( str[i] );
	}
	putchar('\n');

	return 0;
}