Problem: 

Input

The input contains a single integer a (0 ≤ a ≤ 35).

Output

Output a single integer.

Examples

Input

3


Output

8


Input

10


Output

1024

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
int main() {
  map<int, string> m;
  m[1] = "Washington";
  m[2] = "Adams";
  m[3] = "Jefferson";
  m[4] = "Madison";
  m[5] = "Monroe";
  m[6] = "Adams";
  m[7] = "Jackson";
  m[8] = "Van Buren";
  m[9] = "Harrison";
  m[10] = "Tyler";
  m[11] = "Polk";
  m[12] = "Taylor";
  m[13] = "Fillmore";
  m[14] = "Pierce";
  m[15] = "Buchanan";
  m[16] = "Lincoln";
  m[17] = "Johnson";
  m[18] = "Grant";
  m[19] = "Hayes";
  m[20] = "Garfield";
  m[21] = "Arthur";
  m[22] = "Cleveland";
  m[23] = "Harrison";
  m[24] = "Cleveland";
  m[25] = "McKinley";
  m[26] = "Roosevelt";
  m[27] = "Taft";
  m[28] = "Wilson";
  m[29] = "Harding";
  m[30] = "Coolidge";
  m[31] = "Hoover";
  m[32] = "Roosevelt";
  m[33] = "Truman";
  m[34] = "Eisenhower";
  m[35] = "Kennedy";
  m[36] = "Johnson";
  m[37] = "Nixon";
  m[38] = "Ford";
  m[39] = "Carter";
  m[40] = "Reagan";
  m[41] = "Bush";
  m[42] = "Clinton";
  m[43] = "Bush";
  m[44] = "Obama";
  int x;
  cin >> x;
  cout << m[x] << endl;
  return 0;
}