Little X has met the following problem recently. 

Let's define f(x) as the sum of digits in decimal representation of number x (for example, f(1234) = 1 + 2 + 3 + 4). You are to calculate <image>

Of course Little X has solved this problem quickly, has locked it, and then has tried to hack others. He has seen the following C++ code: 
    
    
      
        ans = solve(l, r) % a;  
        if (ans <= 0)  
          ans += a;  
      
    

This code will fail only on the test with <image>. You are given number a, help Little X to find a proper test for hack.

Input

The first line contains a single integer a (1 ≤ a ≤ 1018).

Output

Print two integers: l, r (1 ≤ l ≤ r < 10200) — the required test data. Leading zeros aren't allowed. It's guaranteed that the solution exists.

Examples

Input

46


Output

1 10


Input

126444381000032


Output

2333333 2333333333333
import java.util.*;
import java.io.*;
import java.lang.*;
import java.math.*;
public class D {
    public static void main(String[] args) throws Exception {
        BufferedReader bf = new BufferedReader(new InputStreamReader(System.in));
        // Scanner scan = new Scanner(System.in);
        // PrintWriter out = new PrintWriter(new OutputStreamWriter(System.out)); 
        long n = Long.parseLong(bf.readLine());
        String zero = ""; String nine = "";
        for(int i=0; i<30; i++) {
            zero += "0";
            nine += "9";
        }
        BigInteger b = new BigInteger("1396"+zero);
        b = b.mod(BigInteger.valueOf(n));
        long val = b.longValue();
        if(val == 0) System.out.println("1"+zero+" 10"+nine);
        else {
            long toadd = n - val - 1;
            long numzeros = 30-(toadd+"").length();
            String s = "";
            s += toadd;
            for(int i=0; i<numzeros; i++) s = "0" + s;
            toadd+=1;
            long numzeros2 = 30-(toadd+"").length();
            String s2 = "";
            s2 += toadd;
            for(int i=0; i<numzeros2; i++) s2 = "0" + s2;
            
            System.out.println((1 + s2) + " 11" + s);
        }
        // StringTokenizer st = new StringTokenizer(bf.readLine());
        // int[] a = new int[n]; for(int i=0; i<n; i++) a[i] = Integer.parseInt(st.nextToken());
        // int n = Integer.parseInt(st.nextToken());
        // int n = scan.nextInt();
        
        // out.close(); System.exit(0);
    }
}