#include<bits/stdc++.h> using namespace std; int n,s; int main(){ cin >> n; while(n!=0){ s=s*10+n%10; n=n/10; } cout << s; return 0; }