#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
#ifdef _WIN32
#define getchar_unlocked _getchar_nolock
#endif
#define int long long
#define mp make_pair
#define mt make_tuple
#define pb push_back
#define pf push_front
#define ppb pop_back
#define ppf pop_front
#define eb emplace_back
#define g0(a) get<0>(a)
#define g1(a) get<1>(a)
#define g2(a) get<2>(a)
#define g3(a) get<3>(a)
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
typedef double db;
typedef long long ll;
typedef long double ld;
typedef pair<int, int> ii;
typedef tuple<int, int, int> iii;
typedef tuple<int, int, int, int> iiii;
typedef tree<ii, null_type, less<ii>, rb_tree_tag, tree_order_statistics_node_update> ordered_set;
 
main() {
	ios::sync_with_stdio(0);
	cin.tie(0);
	int X;
	cin >> X;
	int OX = X;
	X++;
	while (X % 100) X++;
	cout << X - OX << '\n';
}

//in dp prefix suffix sum helps..
#include<iostream>
#include<vector>
#include<string.h>
#include<algorithm>
#include<iomanip>
#include<cmath>
#include<stack>
#include <iterator>
#include <map>
#include<list>
#include <fstream>
#include<unordered_map>
#include<set>
#include<queue>
#define int  long long
#define double long double
#define pb   push_back
#define mp   make_pair
#define pii  pair<int,int>
#define pip pair<int, pair<int, int> >
#define viv vector<vector<int> >
#define vip vector< pair<int, int> >
#define vi vector<int>
#define mii  map<pii, int>
#define qu queue<int>
#define set set<int>
#define multi multiset<int>
#define stack stack<int>
#define fi first
#define se second
#define reverse(s) reverse(s.begin(), s.end())
#define sort1(v) sort(v.begin(), v.end())
#define it iterator
#define pq1 priority_queue <pii, vector<pii>, greater<pii> >
#define mem(x, y) memset(x, (int)y, sizeof(x))
#define ps(x,y) fixed<<setprecision(y)<<x
// author :: Anurag Anand.
using namespace std;
int z=  1e9+7;
//int z= 998244353;
int gcd(int a, int b){
    if(a==0)return b;
    if(b==0)return a;
    return gcd(b, a%b);
}
int power(int a,int b)
{
	int res=1;
	while(b)
	{
		if(b&1)
		{
			res=(res*a)%z;
			b--;
		}
		else
		{
			a=(a*a)%z;
			b=b>>1;
		}
	}
	return res;
}
vi sieve;
// vi seg;
// void arrange(int i, int v, int x, int lx, int rx){
// 	if(rx-lx==1){
// 		seg[x]+=v;
// 		return;
// 	}
// 	int m= (lx+rx)/2;
// 	if(i<m) arrange(i, v, 2*x+1, lx, m);
// 	else arrange(i, v, 2*x+2, m, rx);
// 	seg[x]=seg[2*x+1]+seg[2*x+2];
// }
// int calc(int l, int r, int x, int lx, int rx){
// 	if(l>=rx||r<=lx) return 0;
// 	if(lx>=l&&rx<=r) return seg[x];
// 	int mid=(lx+rx)/2;
// 	int sl= calc(l, r, 2*x+1, lx, mid), sr= calc(l, r, 2*x+2, mid, rx);
// 	return sl+sr;
// }
int32_t main()
{
    ios_base::sync_with_stdio(false);
	cin.tie(NULL);
    cout.tie(NULL);
	vi pp;
	pp.assign(1000001, 0);
	for(int i=2;i<1000;i++){
		if(!pp[i]){
			for(int j=i*i;j<=1000000;j+=i){
				pp[j]=1;
			}
		}
	}
	for(int i=2;i<=1000000;i++) if(!pp[i]) sieve.pb(i);
	int t;
	t=1;
	//cin>>t;
	while(t--){
		int x;
		cin>>x;
		cout<<(100-x%100)<<"\n";
	}
}