

Input

The input contains a single integer a (1 ≤ a ≤ 40).

Output

Output a single string.

Examples

Input

2


Output

Adams


Input

8


Output

Van Buren


Input

29


Output

Harding
#include <bits/stdc++.h>
using namespace std;
int main() {
  vector<string> V;
  V.push_back("Washington");
  V.push_back("Adams");
  V.push_back("Jefferson");
  V.push_back("Madison");
  V.push_back("Monroe");
  V.push_back("Adams");
  V.push_back("Jackson");
  V.push_back("Van Buren");
  V.push_back("Harrison");
  V.push_back("Tyler");
  V.push_back("Polk");
  V.push_back("Taylor");
  V.push_back("Fillmore");
  V.push_back("Pierce");
  V.push_back("Buchanan");
  V.push_back("Lincoln");
  V.push_back("Johnson");
  V.push_back("Grant");
  V.push_back("Hayes");
  V.push_back("Garfield");
  V.push_back("Arthur");
  V.push_back("Cleveland");
  V.push_back("Harrison");
  V.push_back("Cleveland");
  V.push_back("McKinley");
  V.push_back("Roosevelt");
  V.push_back("Taft");
  V.push_back("Wilson");
  V.push_back("Harding");
  V.push_back("Coolidge");
  V.push_back("Hoover");
  V.push_back("Roosevelt");
  V.push_back("Truman");
  V.push_back("Eisenhower");
  V.push_back("Kennedy");
  V.push_back("Johnson");
  V.push_back("Nixon");
  V.push_back("Ford");
  V.push_back("Carter");
  V.push_back("Reagan");
  int n;
  scanf("%d", &n);
  cout << V[n - 1] << endl;
  return 0;
}
