#include<bits/stdc++.h> using namespace std; int main(){ int b,d,a,c,e; cin>>a; while(a){ c=c*10+a%10; a/=10; } cout<<c; return 0; }