#include <bits/stdc++.h>
using namespace std;
using ll = long long;
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";
  int k;
  cin >> k;
  int i = 0;
  int count = 0;
  string n;
  while (true) {
    if (s[i] != ',' && s[i] != ' ') {
      if (s[i + 1] != ',' && s[i + 1] != ' ') {
        n = s[i] + s[i + 1];
        i++;
      } else {
        n = s[i];
      }
      count++;
      if (count == k) {
        break;
      }
    }
    i++;
  }
  cout << n << endl;
}
