

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;
string x;
int y;
int main() {
  cin >> y;
  if (y == 1) {
    cout << "Washington" << endl;
  } else if (y == 2) {
    cout << "Adams" << endl;
  } else if (y == 3) {
    cout << "Jefferson" << endl;
  } else if (y == 4) {
    cout << "Madison" << endl;
  } else if (y == 5) {
    cout << "Monroe" << endl;
  } else if (y == 6) {
    cout << "Adams" << endl;
  } else if (y == 7) {
    cout << "Jackson" << endl;
  } else if (y == 8) {
    cout << "Van Buren" << endl;
  } else if (y == 9) {
    cout << "Harrison" << endl;
  } else if (y == 10) {
    cout << "Tyler" << endl;
  } else if (y == 11) {
    cout << "Polk" << endl;
  } else if (y == 12) {
    cout << "Taylor" << endl;
  } else if (y == 13) {
    cout << "Fillmore" << endl;
  } else if (y == 14) {
    cout << "Pierce" << endl;
  } else if (y == 15) {
    cout << "Buchanan" << endl;
  } else if (y == 16) {
    cout << "Lincoln" << endl;
  } else if (y == 17) {
    cout << "Johnson" << endl;
  } else if (y == 18) {
    cout << "Grant" << endl;
  } else if (y == 19) {
    cout << "Hayes" << endl;
  } else if (y == 20) {
    cout << "Garfield" << endl;
  } else if (y == 21) {
    cout << "Arthur" << endl;
  } else if (y == 22) {
    cout << "Cleveland" << endl;
  } else if (y == 23) {
    cout << "Harrison" << endl;
  } else if (y == 24) {
    cout << "Cleveland" << endl;
  } else if (y == 25) {
    cout << "McKinley" << endl;
  } else if (y == 26) {
    cout << "Roosevelt" << endl;
  } else if (y == 27) {
    cout << "Taft" << endl;
  } else if (y == 28) {
    cout << "Wilson" << endl;
  } else if (y == 29) {
    cout << "Harding" << endl;
  } else if (y == 30) {
    cout << "Coolidge" << endl;
  } else if (y == 31) {
    cout << "Hoover" << endl;
  } else if (y == 32) {
    cout << "Roosevelt" << endl;
  } else if (y == 33) {
    cout << "Truman" << endl;
  } else if (y == 34) {
    cout << "Eisenhower" << endl;
  } else if (y == 35) {
    cout << "Kennedy" << endl;
  } else if (y == 36) {
    cout << "Johnson" << endl;
  } else if (y == 37) {
    cout << "Nixon" << endl;
  } else if (y == 38) {
    cout << "Ford" << endl;
  } else if (y == 39) {
    cout << "Carter" << endl;
  } else if (y == 40) {
    cout << "Reagan" << endl;
  }
  return EXIT_SUCCESS;
}
