https://numbas.mathcentre.ac.uk/question/39883/michael-s-copy-of-calculating-expected-values-given-a-table-of-probabilities/embed/