//17571@nith.ac.in @Ankit Verma
#include <bits/stdc++.h>
#define bolt ios::sync_with_stdio(false)
#define ull unsigned long long
#define ll long long
#define pb push_back
#define eb emplace_back
#define ff first
#define ss second
using namespace std;

int main() {

#ifndef ONLINE_JUDGE
/*		freopen("input.txt", "r", stdin);
		freopen("output.txt", "w", stdout);
#endif*/

	bolt;
	cin.tie(nullptr);
	cout.tie(nullptr);
	int ar[] = {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; cin >> n;
	n--;
	cout << ar[n] << endl;
	

	return 0;
}