#include<bits/stdc++.h>
using namespace std;
int main() {
int x;
cin >> x;
int hundreds = x / 100;
int tens = (x % 100) / 10;
int units = x % 10;
int reversedNum = units * 100 + tens * 10 + hundreds;
cout << reversedNum << endl;
return 0;
}
/**************************************************************
Problem: 1028
User: huanghao
Language: C++
Result: Accepted
Time:8 ms
Memory:2072 kb
****************************************************************/