from random import randint def simule(): test = randint(1, 250) if test == 1: return 1 else: return 0 def echantillon(): ech = 0 for k in range(1000): ech = ech + simule() return ech / 1000 from matplotlib.pyplot import * def graphique(N): scatter([k for k in range(N)], [echantillon() for k in range(N)]) show()