#include <bits/stdc++.h>
using namespace std;
int main()
{
vector<char> ch;
char s;
while(cin>>s)
ch.push_back(s);
ostream_iterator<char> os(cout); //输入流迭代器
copy(ch.rbegin(), ch.rend(), os);
return 0;
}

#include <bits/stdc++.h>
using namespace std;
int main()
{
vector<char> ch;
char s;
while(cin>>s)
ch.push_back(s);
ostream_iterator<char> os(cout); //输入流迭代器
copy(ch.rbegin(), ch.rend(), os);
return 0;
}