#include <iostream>
#include <algorithm>
#include <vector>
using namespace std;

int find_binary(int target, vector<int> &arr)
{
    if (arr.empty())
        return -1;
    int low = 0;
    int high = arr.size() - 1;

    while (low <= high)
    {
        int middle = (low + high) / 2;
        if (target == arr[middle])
            return 1;
        else if (target > arr[middle])
            low = middle + 1;

        else
            high = middle - 1;
    }
    return -1;
}

int main()
{
    int b;
    int a[] = {1, 2, 3, 3, 5, 6};
    int len = sizeof(a) / sizeof(int);
    vector<int> arr(a, a + len);
    std::sort(arr.begin(), arr.end());
    vector<int>::iterator it;
    scanf("%d", &b);
    cout << find_binary(b, arr) << endl;

    return 0;
}
