Problem: Apart from having lots of holidays throughout the year, residents of Berland also have whole lucky years. Year is considered lucky if it has no more than 1 non-zero digit in its number. So years 100, 40000, 5 are lucky and 12, 3001 and 12345 are not.

You are given current year in Berland. Your task is to find how long will residents of Berland wait till the next lucky year.

Input

The first line contains integer number n (1 ≤ n ≤ 109) — current year in Berland.

Output

Output amount of years from the current year to the next lucky one.

Examples

Input

4


Output

1


Input

201


Output

99


Input

4000


Output

1000

Note

In the first example next lucky year is 5. In the second one — 300. In the third — 5000.

Solution (in JAVA):

Solution:
import java.io.*;
import java.util.*;
public class E21A
{
    static PrintWriter out=new PrintWriter((System.out));
    public static void main(String args[])throws IOException
    {
        Reader sc=new Reader();
        String n=sc.next();
        int d=n.charAt(0)-48;
        d++;
        String s=d+"";
        for(int x=1;x<n.length();x++)
        {
            s=s+"0";
        }
        out.println(Integer.parseInt(s)-Integer.parseInt(n));
        out.close();
    }
    static Set<Integer> set;

    public static void inorder(LinkedList<Integer> graph[],int ar[],int root,int min,int max)
    {
        int a=graph[root].get(0);
        int b=graph[root].get(1);
        if(ar[root]>min&&ar[root]<max)
        {
            set.add(ar[root]);
        }
        if(a!=-1)
        {
            inorder(graph,ar,a,min,Math.min(ar[root],max));
        }
        if(b!=-1)
        {
            inorder(graph,ar,b,Math.max(ar[root],min),max);
        }
    }

    static class Reader 
    { 
        BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
        StringTokenizer st=new StringTokenizer("");
        public String next()
        {
            while(!st.hasMoreTokens())
            {
                try
                {
                    st=new StringTokenizer(br.readLine());
                }
                catch(Exception e)
                {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

        public int nextInt()
        {
            return Integer.parseInt(next());
        }

        public long nextLong()
        {
            return Long.parseLong(next());
        }

        public double nextDouble()
        {
            return Double.parseDouble(next());
        }

        public String nextLine()
        {
            try
            {
                return br.readLine();
            }
            catch(Exception e)
            {
                e.printStackTrace();
            }
            return null;
        }

        public boolean hasNext()
        {
            String next=null;
            try
            {
                next=br.readLine();
            }
            catch(Exception e)
            {
            }
            if(next==null)
            {
                return false;
            }
            st=new StringTokenizer(next);
            return true;
        }
    } 
}