#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int a, b;
  cin >> a >> b;
  a = max(a, b);
  for (int i = 1; i <= a; i++) cout << "8";
  cout << "9";
  cout << "\n";
  for (int i = 1; i <= a + 1; i++) cout << "1";
  return 0;
}
