40. Let X₁,..., Xₙ be a sample from a Bernoulli distribution with an unknown parameter p ∈ [0, 1]. We want to give a Bayesian estimate for the variance var(X) = p(1 - p) with respect to a beta(α, β) prior distribution with parameter p.
(i) Determine the posterior density for p.
(ii) Determine the Bayes estimators for p and varp(X).