fork download
  1. def suma_dzielnikow_1(n):
  2. suma = 0
  3. for j in range(1, n + 1):
  4. if n % j == 0:
  5. suma += j
  6. return suma
  7.  
  8. print(suma_dzielnikow_1(10))
Success #stdin #stdout 0.08s 14156KB
stdin
Standard input is empty
stdout
18