#include <bits/stdc++.h>
using namespace std;
const double eps = 1e-10, pi = 3.1415926535898;
const int mod = 1e9 + 7, maxn = 1e3 + 10;
int T, n, m, k, x, y;
double dp[maxn][maxn];
int main(int argc, char const *argv[]) {
  for (int i = 0; i < maxn; ++i) {
    dp[i][0] = 1;
    dp[0][i] = 1.0 / (i + 1);
  }
  for (int i = 2; i < 2 * maxn; ++i) {
    for (int j = 1; j < i; ++j) {
      x = j;
      y = i - j;
      if (x >= maxn or y >= maxn) continue;
      double k1 = -dp[0][y] - dp[y - 1][x] * y / (y + 1);
      double k2 = dp[y][x - 1] - dp[y - 1][x] * y / (y + 1);
      double p = dp[y][x - 1] / (k2 - k1);
      dp[x][y] = k1 * p + 1;
    }
  }
  scanf("%d %d", &n, &m);
  printf("%.10lf %.10lf\n", dp[n][m], 1 - dp[n][m]);
  return 0;
}
