def ajoute(n,p): somme = 0 for i in range(.........): # ligne à modifier somme = somme + i return somme