#include<bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using LL = long long;
using P = pair<int,int>;


int main(){
	string S;
	cin >> S;
	if(S.size()==2) {
		cout << S << endl;
	}
	else cout << S[2] << S[1] << S[0] << endl;	
}








#include<bits/stdc++.h>
using namespace std;

int main(){
  int N,t;
  
  cin >> N;
  t=N;
  
  int f=0;
  
  for(int i=0;i<9;i++){
    f = f+ (t%10);
    t=t/10;
  }
  
  if(N%f==0)cout<<"Yes"<<endl;
  else cout<<"No"<<endl;
  
}