public class Euler398 {
    private static double ratioBinomDrop(long a, int drop, int chooseR) {
        double ratio = 1.0;
        for (int j = 0; j < chooseR; ++j) {
            ratio *= (double) (a - drop - j) / (double) (a - j);
        }
        return ratio;
    }

    private static double expectedSecondShortest(long n, int m) {
        int r = m - 1;
        long aR = n - 1;
        long aS = n - 1;
        double ratioR = 1.0;
        double ratioS = 1.0;

        double answer = 0.0;
        while (true) {
            double tail = (double) (m) * ratioR - (double) (m - 1) * ratioS;
            answer += tail;

            boolean hasNext = false;
            if (aR - (m - 1) >= r) {
                ratioR *= ratioBinomDrop(aR, m - 1, r);
                aR -= (m - 1);
                hasNext = true;
            } else {
                ratioR = 0.0;
            }

            if (aS - m >= r) {
                ratioS *= ratioBinomDrop(aS, m, r);
                aS -= m;
                hasNext = true;
            } else {
                ratioS = 0.0;
            }

            if (!hasNext) {
                break;
            }
        }
        return answer;
    }

    public static String solve() {
        long n = 10000000L;
        int m = 100;
        return String.format("%.5f", expectedSecondShortest(n, m)).replace(',', '.');
    }

    public static void main(String[] args) {
        System.out.println(solve());
    }
}
