#include <iostream>
#include <algorithm>
#include <math.h>
#include <iomanip>
using namespace std;
int main()
{
int a = 0;
bool A, Uim, ba, zheng = false;
cin >> a;
if (a % 2 == 0 and a > 4 and a <= 12)
A = true;
if (a % 2 == 0)
Uim = true;
if (a > 4 and a <= 12)
Uim = true;
if (a % 2 == 0)
ba = true;
if (a > 4 and a <= 12)
ba = true;
if (a % 2 == 0, a > 4, a <= 12)
ba = false;
if (a % 2 == 1 and a <= 4 and a > 12)
zheng = true;
cout << A <<" " <<Uim <<" " << ba <<" " << zheng;
return 0;
}