#include <bits/stdc++.h>
using namespace std;
const long long INF = 1e9;
const long long MAX_N = 6e5 + 5;
int main() {
  long long n, m;
  cin >> n >> m;
  cout << string(n, '5') << '\n' << string(n - 1ll, '4') << 5;
  return 0;
}
