#include <bits/stdc++.h>
using namespace std;
bool chmin(long long int &a, long long int &b) {
  if (b < a) {
    a = b;
    return 1;
  }
  return 0;
}
bool chmax(long long int &a, long long int &b) {
  if (b > a) {
    a = b;
    return 1;
  }
  return 0;
}
const long long int inf = 1LL << 60;
const long long int mod = 1e9 + 7;
const long long int max = 500010;
long long int num, M, N, ans = 0, count = 0;
int main() {
  string S = {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};
  long long int K;
  cin >> K;
  cout << S[K - 1] << endl;
  return 0;
}
