#include <functional>
#include <algorithm>
#include <iostream>
#include <iomanip>
#include <cstring>
#include <string>
#include <vector>
#include <random>
#include <bitset>
#include <queue>
#include <cmath>
#include <stack>
#include <set>
#include <map>
typedef long long ll;
using namespace std;
const ll MOD = 1000000007LL;

int main() {
    cin.sync_with_stdio(false);
    cin.tie(0);
    cout.tie(0);

    int x;
    cin >> x;

    vector <bool> dp(100001);
    dp[0] = true;

    for (int i = 0; i < 6; i++) {
        for (int j = 100000; j - 100 - i >= 0; j--) {
            if (dp[j - 100 - i]) {
                dp[j] = true;
            }
        }
    }

    cout << (dp[x] ? 1 : 0) << "\n";
    return 0;
}