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
def f(x, l):
    return (45 * l + 10 * x) * (10 ** (l-1))

a = int(input())
L = 1
x = 0
if a < 10000 : a *= 10000
while f(x, L + 1) < a : 
    L += 1
while f(x + 1, L) < a : 
    x += 1
now = f(x, L)
add = a - now

di = 0
t = 0
while(di < x):
    if di + 9 <= x : 
        t = t * 10 + 9
        di += 9
    else:
        t = t * 10 + (x - di)
        di = x

t *= 10
l = t * (10 ** L) + add
r = (t + 1) * (10 ** L) + add - 1
print(l, r)

    