#include <iostream>
using namespace std;
int main(){
int n;
cin >> n;
while (n > 0) {
int last = n % 10;
cout << last;
n /= 10;
}
return 0;
#include <iostream>
using namespace std;
int main(){
int n;
cin >> n;
while (n > 0) {
int last = n % 10;
cout << last;
n /= 10;
}
return 0;
}