קורס פייתון תרגיל 5

"""The program choose a random numbers
between 1 - 1000000 until it find number
which divided by 7 ,13 and 15"""

from random import randint
for i in range(1000000):
    num = randint(1,1000000)
    if num % 7 ==0 and num % 13 ==0 and num % 15 ==0:
        break
print num
לייק 1