Source: https://users.ox.ac.uk/~logicman/exercises/exercises_peter.pdf