#include <bits/stdc++.h>
using namespace std;
using LL = long long;
const int N = 1024;
const int INF = INT32_MAX - 1;
const double EPS = 1E-9;
int a[N] = {0, 1, 1, 1, 2, 1, 2, 1,  5, 2, 2, 1, 5, 1, 2, 1, 14,
            1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51};
int n, m;
int main() {
  ios_base::sync_with_stdio(false);
  int v;
  cin >> v;
  cout << a[v] << endl;
  return 0;
}
