log likelihood function of bernoulli distribution