Problem: Alex enjoys performing magic tricks. He has a trick that requires a deck of n cards. He has m identical decks of n different cards each, which have been mixed together. When Alex wishes to perform the trick, he grabs n cards at random and performs the trick with those. The resulting deck looks like a normal deck, but may have duplicates of some cards.

The trick itself is performed as follows: first Alex allows you to choose a random card from the deck. You memorize the card and put it back in the deck. Then Alex shuffles the deck, and pulls out a card. If the card matches the one you memorized, the trick is successful.

You don't think Alex is a very good magician, and that he just pulls a card randomly from the deck. Determine the probability of the trick being successful if this is the case.

Input

First line of the input consists of two integers n and m (1 ≤ n, m ≤ 1000), separated by space — number of cards in each deck, and number of decks.

Output

On the only line of the output print one floating point number – probability of Alex successfully performing the trick. Relative or absolute error of your answer should not be higher than 10 - 6.

Examples

Input

2 2


Output

0.6666666666666666


Input

4 4


Output

0.4000000000000000


Input

1 2


Output

1.0000000000000000

Note

In the first sample, with probability <image> Alex will perform the trick with two cards with the same value from two different decks. In this case the trick is guaranteed to succeed.

With the remaining <image> probability he took two different cards, and the probability of pulling off the trick is <image>.

The resulting probability is <image>

Solution (in JAVA):

Solution:
import java.io.*;
import java.math.BigInteger;
import java.util.StringTokenizer;

public class C {

    static class Ratio {
        BigInteger p, q;

        Ratio(long p) {
            this(BigInteger.valueOf(p));
        }

        Ratio(BigInteger p) {
            this(p, BigInteger.ONE);
        }

        Ratio(BigInteger p, BigInteger q) {
            BigInteger g = p.abs().gcd(q.abs());
            this.p = p.divide(g);
            this.q = q.divide(g);
            if (this.q.signum() < 0) {
                this.p = this.p.negate();
                this.q = this.q.negate();
            }

        }

        Ratio add(Ratio r) {
            return new Ratio(p.multiply(r.q).add(q.multiply(r.p)), q.multiply(r.q));
        }

        Ratio multiply(Ratio r) {
            return new Ratio(p.multiply(r.p), q.multiply(r.q));
        }

        Ratio divide(Ratio r) {
            return new Ratio(p.multiply(r.q), q.multiply(r.p));
        }

        @Override
        public String toString() {
            return p + "/" + q;
        }

        public double toDouble() {
            if (p.bitLength() > 100 && q.bitLength() > 100) {
                int sh = p.bitLength() - 100;
                return p.shiftRight(sh).doubleValue() / q.shiftRight(sh).doubleValue();
            }
            return p.doubleValue() / q.doubleValue();
        }
    }
//
//    static class Ratio {
//        double d;
//
//        Ratio(double p) {
//            this.d = p;
//        }
//
//        Ratio(BigInteger p) {
//            this(p.doubleValue());
//        }
//
//        Ratio(BigInteger p, BigInteger q) {
//            this(p.doubleValue() / q.doubleValue());
//        }
//
//
//        Ratio add(Ratio r) {
//            return new Ratio(d + r.d);
//        }
//
//        Ratio multiply(Ratio r) {
//            return new Ratio(d * r.d);
//        }
//
//        Ratio divide(Ratio r) {
//            return new Ratio(d / r.d);
//        }
//
//        @Override
//        public String toString() {
//            return "" + d;
//        }
//    }
//

    static Ratio fact(int n) {
        BigInteger res = BigInteger.ONE;
        for (int i = 2; i <= n; i++) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        return new Ratio(res);
    }

    static Ratio c(int n, int k) {
        Ratio r1 = new Ratio(1);
        for (int i = n - k + 1; i <= n; i++) {
            r1 = r1.multiply(new Ratio(i));
        }
        return r1.divide(fact(k));
    }

    static Ratio get(int n, int m, int k) {
        Ratio res = c(n, k).divide(fact(m - k)).multiply(fact(m));
        BigInteger accDiv = BigInteger.ONE;
        for (int i = n * m - n + 1; i <= n * m; i++) {
//            res = res.divide(new Ratio(i));
            accDiv = accDiv.multiply(BigInteger.valueOf(i));
        }
        res = res.divide(new Ratio(accDiv));
        BigInteger accMul = BigInteger.ONE;
        for (int i = n * m - n - m + k + 1; i <= n * m - m; i++) {
//            res = res.multiply(new Ratio(i));
            accMul = accMul.multiply(BigInteger.valueOf(i));
        }
        res = res.multiply(new Ratio(accMul));
        return res;
    }

    void solve() throws IOException {
        int n = in.nextInt();
        int m = in.nextInt();
//        Ratio res = new Ratio(0);
//        Ratio p = null;
//        for (int k = 1; k <= Math.min(n, m); k++) {
//            if (p == null) {
//                p = get(n, m, k);
//            } else {
//                p = p.multiply(new Ratio((m - k + 1) * (n - k + 1))).divide(new Ratio((n * m - n - m + k) * k));
////                p = get(n, m, k);
//            }
//            Ratio succ = new Ratio(BigInteger.valueOf(k), BigInteger.valueOf(n));
//            succ = succ.multiply(succ);
////            System.err.println(k + " : +" + p.multiply(succ));
//            res = res.add(p.multiply(succ));
//        }
//        Ratio ans = res.multiply(new Ratio(n));
////        System.err.println(ans.p.doubleValue() / ans.q.doubleValue());
//        System.err.println(ans);
//        System.err.println(get(2, 2, 0));
//        System.err.println(get(2, 2, 1));
//        System.err.println(get(2, 2, 2));
        double res = 0;
        Ratio firstP = get(n, m, 1);
        double p = firstP.toDouble();
//        System.err.println(p);
        for (int k = 1; k <= Math.min(n, m); k++) {
            if (k != 1) {
                p = p * (m - k + 1) * (n - k + 1) / (n * m - n - m + k) / k;
            }
//            System.err.println(p);
            double succ = k / 1. / n;
            succ *= succ;
            res += p * succ;
        }
        res *= n;
        out.println(res);
//        System.err.println(res);
//        Ratio ans = res.multiply(new Ratio(n));
//
    }

    static MyScanner in;
    static PrintWriter out;

    public static void main(String[] args) throws IOException {
        in = new MyScanner(new InputStreamReader(System.in));
        out = new PrintWriter(System.out);
        new C().solve();
        out.close();
    }

    public static class MyScanner {
        BufferedReader br;
        StringTokenizer st;

        public MyScanner(Reader r) {
            br = new BufferedReader(r);
        }

        String next() throws IOException {
            while (st == null || !st.hasMoreTokens()) {
                st = new StringTokenizer(br.readLine());
            }
            return st.nextToken();
        }

        int nextInt() throws IOException {
            return Integer.parseInt(next());
        }
    }
}