Source: https://people.mio.osupytheas.fr/~nerini/cours/statM1/TD4-StatM1-tests.pdf