#include <bits/stdc++.h>
long long gi() {
  long long x = 0, f = 1;
  char ch = getchar();
  while (!isdigit(ch)) f ^= ch == '-', ch = getchar();
  while (isdigit(ch)) x = x * 10 + ch - '0', ch = getchar();
  return f ? x : -x;
}
double f[2010][2010];
int main() {
  int n = gi(), m = gi(), N = std::max(n, m);
  for (int i = 0; i <= N; ++i) f[i][0] = 1, f[0][i] = 1. / (i + 1);
  for (int s = 1; s <= n + m; ++s)
    for (int i = 1, j; i < s; ++i) {
      j = s - i;
      double A = 1. * j / (j + 1) * (1 - f[j - 1][i]), B = A + 1. / (j + 1);
      double C = 1, D = 1 - f[j][i - 1];
      double p = (D - B) / (A - B - C + D);
      f[i][j] = p * A + (1 - p) * B;
    }
  printf("%.10lf %.10lf\n", f[n][m], 1 - f[n][m]);
  return 0;
}
