repl.it
@acwoss/

FarawayOblongRepository

Python

No description

fork
loading
Files
  • main.py
main.py
1
2
3
4
5
6
7
8
9
def divisores(*numeros):
  menor = min(numeros)
  for i in range(1, menor+1):
    if all(numero % i == 0 for numero in numeros):
      yield i
      
print('Divisores de 5 e 10:', list(divisores(5, 10)))
print('Divisores de 42, 100 e 999:', list(divisores(42, 100, 999)))
print('Divisores de 14, 38 e 74:', list(divisores(14, 38, 74)))