#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false), cin.tie(0);
  int n, m;
  cin >> n >> m;
  for (int i = 0; i < n; i++) {
    cout << 5;
  }
  cout << "\n";
  for (int i = 0; i < n; i++) {
    if (i == n - 1)
      cout << 5;
    else
      cout << 4;
  }
  cout << "\n";
}
