#include<bits/stdc++.h>
using namespace std;
#define pb push_back
#define ll long long
#define vi vector <int>
#define vl vector <ll>
#define vii vector < pair <int,int> >
#define vll vector < pair <ll,ll> > 
#define mii map<int,int>
#define mll map<ll,ll>
#define si set <int>
#define sl set <ll>
#define all(a) a.begin(),a.end()
#define pii pair<int,int>
#define rep(i,a,n) for(ll i=a ; i<n ; i++)
#define fastio ios::sync_with_stdio(false);cin.tie(0);cout.tie(0);

ll binomialCoeff(ll n, ll k) 
{ 
    ll res = 1; 
  
    // Since C(n, k) = C(n, n-k) 
    if (k > n - k) 
        k = n - k; 
  
    // Calculate value of 
    // [n * (n-1) *---* (n-k+1)] / [k * (k-1) *----* 1] 
    for (ll i = 0; i < k; ++i) { 
        res *= (n - i); 
        res /= (i + 1); 
    } 
  
    return res; 
} 
struct MyComp
{
    bool operator()(const pair<int,int>& x, const pair<int,int>& y) const
    {
        return x.second > y.second || (x.second == y.second && x.first > y.first);
    }
};
ll M=1e9+7;
ll mods(ll a,ll b){
    a=a%M;
    b=b%M;
    return (a+b)%M;
}
ll modp(ll a,ll b){
    a=a%M;
    b=b%M;
    return (a*b)%M;

}

int main(){
    fastio
    

        int n;cin>>n;
        cout<<100-(n%100)<<endl;
        


    


    

    
    
    
}
//n = unique(a, a + n) - a;
/*
        @uthor: Kashish Gilhotra
        user: CodeChef, CodeForces, HackerEarth, HackerRank, SPOJ: kashish001
*/

#include <bits/stdc++.h>
using namespace std;
  
#define int long long int 
typedef vector<int> vi;
typedef vector<pair<int, int>> vpi;
typedef vector<vi> vvi;
const int mod = 1e9 + 7; 

#define FAST ios_base::sync_with_stdio(false); cin.tie(NULL) 
#define debug(...) cerr << "[" << #__VA_ARGS__ ": " << (__VA_ARGS__) << "] " 
#define EB emplace_back
#define ALL(v) v.begin(), v.end() 
#define size(v) (int)v.size() 
#define endl '\n'
#define UMO unordered_map
#define USO unordered_set
#define TC int t; cin >> t; while (t--) 

void Panda() {
    int x;
    cin >> x;
    cout << (x % 100 == 0 ? 100 : ((x - (x % 100) + 100)) - x) << endl;
}
  
int32_t main() {
 
    FAST;

    //freopen("input.txt", "r", stdin); 
    //freopen("output.txt", "w", stdout); 
    
    Panda();

    return 0; 
} 