#include <bits/stdc++.h>
using namespace std;
long long count(long long x) {
  long long ans = 0;
  while (x) {
    ans += x % 10ll;
    x /= 10ll;
  }
  return ans;
}
long long check(long long mid) {
  if (mid < 10) return mid * (mid + 1) / 2ll;
  long long ret = 1;
  long long cnt = 0;
  while (10ll * ret <= mid) ret *= 10ll, cnt++;
  long long x = mid / ret;
  long long cal1 = x * (ret / 2ll) * 9ll * cnt;
  long long s = x - 1;
  long long cal2 = x * (ret / 2ll) * s;
  long long p = mid % ret;
  long long cal3 = check(p) + ((p + 1) * x);
  return cal1 + cal2 + cal3;
}
int32_t main() {
  long long a;
  cin >> a;
  long long lo = 0, hi = 2e16;
  while (hi - lo > 1) {
    long long mid = (hi + lo) / 2ll;
    if (check(mid) <= a)
      lo = mid;
    else
      hi = mid;
  }
  long long r = max(lo, 1ll);
  long long l = 1;
  long long now = check(r);
  while (1) {
    if (now > a && l != r) now -= count(l), l++;
    if (now < a) now += count(r + 1), r++;
    if (now == a) break;
  }
  return cout << l << ' ' << r << endl, 0;
}

### Prompt

Construct a Cpp code solution to the problem outlined:

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

### Response

```cpp
#include <bits/stdc++.h>
using namespace std;
long long count(long long x) {
  long long ans = 0;
  while (x) {
    ans += x % 10ll;
    x /= 10ll;
  }
  return ans;
}
long long check(long long mid) {
  if (mid < 10) return mid * (mid + 1) / 2ll;
  long long ret = 1;
  long long cnt = 0;
  while (10ll * ret <= mid) ret *= 10ll, cnt++;
  long long x = mid / ret;
  long long cal1 = x * (ret / 2ll) * 9ll * cnt;
  long long s = x - 1;
  long long cal2 = x * (ret / 2ll) * s;
  long long p = mid % ret;
  long long cal3 = check(p) + ((p + 1) * x);
  return cal1 + cal2 + cal3;
}
int32_t main() {
  long long a;
  cin >> a;
  long long lo = 0, hi = 2e16;
  while (hi - lo > 1) {
    long long mid = (hi + lo) / 2ll;
    if (check(mid) <= a)
      lo = mid;
    else
      hi = mid;
  }
  long long r = max(lo, 1ll);
  long long l = 1;
  long long now = check(r);
  while (1) {
    if (now > a && l != r) now -= count(l), l++;
    if (now < a) now += count(r + 1), r++;
    if (now == a) break;
  }
  return cout << l << ' ' << r << endl, 0;
}

```