Source: https://maths.langella.free.fr/premiere_S/02_exercices/TP02.pdf