#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long n, m, k;
  cin >> n >> m;
  string s = "", s1 = "";
  for (int i = 0; i < n; i++) {
    s += '1';
    if (i < n - 1) s1 += '8';
  }
  s1 += '9';
  cout << s << endl;
  cout << s1;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  int T = 1;
  while (T--) {
    solve();
    cout << endl;
  }
  return 0;
}
