#include using namespace std; int main(){ string S0; cin >> S0; unordered_map D; D['Z']="1st"; D['B']="2nd"; D['S']="3rd"; D['E']="4th"; D['D']="Alpha"; cout << D[S0[0]] << endl; }