#include <bits/stdc++.h>
using namespace std;
struct fastIO {
  fastIO() {}
};
const int MAXN = 1e6 + 10;
long long a, n, m;
string x, y;
int main() {
  if (0) cerr << fixed << setprecision(20);
  fastIO();
  cin >> n >> m;
  x = '4';
  y = '5';
  while (a < n) {
    a += 9;
    x += "54";
    y += "45";
  }
  cout << x + '5' << endl << y + '5';
  return 0;
}
