@Override
    public double sd() {
        return Math.sqrt(n * p * (1 - p));
    }
@Test
    public void testSd() {
        System.out.println("sd");
        BinomialDistribution instance = new BinomialDistribution(100, 0.3);
        instance.rand();
        assertEquals(Math.sqrt(21.0), instance.sd(), 1E-7);
    }