#include <iostream> using namespace std; int main( void ) { char ch; if( !(cin>>ch) ) return 1; if( ch>='A' && ch<='Z' ) cout << (ch-'A'+1) << endl; else if( ch>='a' && ch<='z' ) cout << (ch-'a'+1) << endl; else if( ch>='0' && ch<='9' ) cout << ch << endl; }