Fix division by part of the test list in bernoulli distribution calculation.