#include <iostream>
#include <string>
#include <algorithm>
#include <iterator>

int main()
{
	std::string str;
	std::cin >> str;
	std::copy(str.rbegin(), str.rend(),
			std::ostream_iterator<char>(std::cout));
	std::cout << std::endl;
	return 0;
}