Given a list of 0/1 observations, return the maximum likelihood estimate of the Bernoulli parameter.
Differentiating the log-likelihood gives the answer everyone guesses anyway, the sample proportion. That it is the MLE is the point: the obvious estimator falls out of the likelihood rather than being assumed.
Input
[1, 0, 1, 1, 0]
Output
0.6