#include <bits/stdc++.h>
using namespace std;
void print(int n) { printf("%d ", n); }
void printl(long long n) { printf("%I64d ", n); }
long long readline() {
  long long x;
  scanf("%I64d", &x);
  return x;
}
template <typename T>
inline void readline(T &n) {
  n = 0;
  int f = 1;
  register int ch = getchar();
  for (; !isdigit(ch); ch = getchar())
    if (ch == '-') f = -1;
  for (; isdigit(ch); ch = getchar()) n = (n << 3) + (n << 1) + ch - '0';
  n = n * f;
}
template <typename T, typename TT>
inline void readline(T &n, TT &m) {
  readline(n);
  readline(m);
}
template <typename T, typename TT, typename TTT>
inline void readline(T &n, TT &m, TTT &l) {
  readline(n, m);
  readline(l);
}
vector<string> split(const string &s, char c) {
  vector<string> v;
  stringstream ss(s);
  string x;
  while (getline(ss, x, c)) v.emplace_back(x);
  return move(v);
}
void err(vector<string>::iterator it) {}
template <typename T, typename... Args>
void err(vector<string>::iterator it, T a, Args... args) {
  cout << it->substr((*it)[0] == ' ', it->length()) << " = " << a << " ";
  err(++it, args...);
}
int dx[8] = {1, 0, -1, 0, -1, -1, 1, 1};
int dy[8] = {0, 1, 0, -1, -1, 1, -1, 1};
const int mod = 1e9 + 7;
const int inf = (int)2e9 + 5;
const long long int Inf = (long long int)2e18 + 5;
const int N = 4e5 + 5;
const int N1 = 1e5 + 5;
bool vis[N1];
int a[N1];
vector<int> v[N1];
int solve() {
  int n;
  cin >> n;
  int a[32] = {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};
  cout << a[n + 1] << endl;
  return 0;
}
int main() {
  int test = 1, tc = 0;
  while (test--) {
    solve();
  }
  return 0;
}
