Problem: Notes

For this problem, it is recommended to use floating point numbers, which are more accurate than double.



Input


m n x
k l y


For input, six integers m, n, x, k, l, y are given in the above input format.
These six integers correspond to those in the problem statement, repeating the horizontal m: n cut x times and the vertical k: l cut y times.
1 ≤ m, n, k, l ≤ 100, 0 ≤ x, y ≤ 40, and m, n and l, k are relatively prime.

Output

Print out the expected number of planarians that are regenerating to their original form after a few weeks in a row.
The output is acceptable with an error of 10-6 or less.

Examples

Input

1 1 1
1 1 1


Output

0.562500


Input

1 2 2
1 1 1


Output

0.490741


Input

1 2 0
3 4 0


Output

1.000000

Solution (in CPP):

Solution:
#include <cstdio>
#include <queue>
#include <algorithm>

#define rep(i, n) for(int i = 0; i < (n); ++i)

using namespace std;

typedef long double ld;

int m, n, x, k, l, y;

ld side(ld a, int k){
	if(k == 0){
		return 1;
	}
	return (2 * a * a - 2 * a + 1) * side(a, k - 1) + a * (1 - a);
}

int main(){
	scanf("%d%d%d%d%d%d", &m, &n, &x, &k, &l, &y);
	printf("%Lf\n", side(n / ld(n + m), x) * side(l / ld(l + k), y));
	return 0;
}