#include <bits/stdc++.h>
using namespace std;
char buf[1 << 21], *p1 = buf, *p2 = buf;
template <class T>
void read(T &x) {
  x = 0;
  int c = getchar();
  int flag = 0;
  while (c < '0' || c > '9') flag |= (c == '-'), c = getchar();
  while (c >= '0' && c <= '9')
    x = (x << 3) + (x << 1) + (c ^ 48), c = getchar();
  if (flag) x = -x;
}
template <class T>
T _max(T a, T b) {
  return b < a ? a : b;
}
template <class T>
T _min(T a, T b) {
  return a < b ? a : b;
}
template <class T>
bool checkmax(T &a, T b) {
  return a < b ? a = b, 1 : 0;
}
template <class T>
bool checkmin(T &a, T b) {
  return b < a ? a = b, 1 : 0;
}
const long long mod = 1000000000, Mod = 1000000000000000000, c = 6 * mod;
long long n, a, d;
struct mat {
  long long a[2][2];
  mat() { memset(a, 0, sizeof a); }
};
mat operator*(mat a, mat b) {
  mat c;
  c.a[0][0] =
      ((__int128)a.a[0][0] * b.a[0][0] + (__int128)a.a[0][1] * b.a[1][0]) % Mod;
  c.a[0][1] =
      ((__int128)a.a[0][0] * b.a[0][1] + (__int128)a.a[0][1] * b.a[1][1]) % Mod;
  c.a[1][0] =
      ((__int128)a.a[1][0] * b.a[0][0] + (__int128)a.a[1][1] * b.a[1][0]) % Mod;
  c.a[1][1] =
      ((__int128)a.a[1][0] * b.a[0][1] + (__int128)a.a[1][1] * b.a[1][1]) % Mod;
  return c;
}
mat operator^(mat a, long long b) {
  mat ans;
  ans.a[0][0] = ans.a[1][1] = 1;
  while (b) {
    if (b & 1) ans = ans * a;
    a = a * a;
    b >>= 1;
  }
  return ans;
}
long long qpow(long long a, long long b) {
  long long ans = 1;
  while (b) {
    if (b & 1) ans = (long long)ans * a % mod;
    a = (long long)a * a % mod;
    b >>= 1;
  }
  return ans;
}
long long M;
void init() {
  read(n);
  read(a);
  read(d);
  mat a, b;
  a.a[0][0] = a.a[0][1] = a.a[1][0] = 1;
  b.a[0][0] = 1;
  b = b * (a ^ c);
  long long t = b.a[0][0] / mod / 4;
  long long phi = mod / 10 * 4;
  M = qpow(t, phi - 1) * 25LL % mod;
  cerr << "M"
       << " = " << M << endl;
}
void solve() {
  long long b = M * a % mod * c + 1;
  long long e = M * d % mod * c;
  printf("%lld %lld\n", b, e);
}
int main() {
  init();
  solve();
  return 0;
}
