#include <bits/stdc++.h>

#define F first
#define S second
#define pb(x) push_back(x)
#define forr(i, a, b) for(int i = a;i <= b;i++)
#define sz(s) int(s.size())
#define ioi ios_base::sync_with_stdio(false)
#define all(x) x.begin(), x.end()
#define tie cin.tie(nullptr);cout.tie(nullptr);
//#define int long long

using namespace std;

int a[] = {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}

main(){ioi;tie;
	int n;cin >> n;
	cout << a[--n];
	/*
	cout <<  ((n + 1) >> 1) ; 
	*/
}

//Coded by LoliThief or ProRedWood or Lolivillian;

